Date: Tue, 20 May 1997 11:43:37 +0200 (METDST) From: Robert Hoehne To: "John M. Aldrich" Cc: DJGPP Workers Mailing List Subject: Re: Bugfix for redir.c In-Reply-To: <337B8C14.3403@cs.com> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Thu, 15 May 1997, John M. Aldrich wrote: > There's a bug in the code for redir from DJGPP v2.01 that causes Because I forgot to take your patch at home, I couldn't look at it. But thought about the problem and I think, I found a much smaller patch, which does exactly the same. It uses the '__dosexec_in_system' variable (I found this when I looked at the system function). *** src/utils/redir.c~ Wed Jul 12 04:06:50 1995 --- src/utils/redir.c Sun May 18 11:30:46 1997 *************** *** 26,31 **** --- 26,32 ---- #include #include #include + #include int _crt0_startup_flags = _CRT0_FLAG_DISALLOW_RESPONSE_FILES; *************** *** 151,157 **** --- 152,160 ---- argv++; } + __dosexec_in_system = 1; rv = spawnvp(P_WAIT, argv[1], argv+1); + __dosexec_in_system = 0; if (rv < 0) fatal("Error attempting to run program %s\n", argv[1]); ***************************************************************** * Robert Hoehne, Fakultaet fuer Mathematik, TU-Chemnitz-Zwickau * * Post: Am Berg 3, D-09573 Dittmannsdorf * * e-Mail: Robert DOT Hoehne AT Mathematik DOT TU-Chemnitz DOT DE * * WWW: http://www.tu-chemnitz.de/~rho * *****************************************************************