From: Pierre Muller <muller@cerbere.u-strasbg.fr>
To: gdb-patches@sources.redhat.com
Subject: Re: [RFA] honor new-console and new-group in win32-nat.c
Date: Fri, 22 Feb 2002 09:05:00 -0000 [thread overview]
Message-ID: <4.2.0.58.20020222175830.01a86430@ics.u-strasbg.fr> (raw)
In-Reply-To: <20020222162808.GA15597@redhat.com>
>Actually. Wait. There's a better way to do this. Sorry.
>
>Just get rid of the flags = 0 and move the useshell stuff prior to
>the flags |=. That's what I'd intended to do but muffed the placement
>of the useshell conditionals.
OK I committed this:
2002-02-22 Pierre Muller <muller@ics.u-strasbg.fr>
* win32-nat.c (child_create_inferior): Fix create flags setting bug.
Index: win32-nat.c
===================================================================
RCS file: /cvs/src/src/gdb/win32-nat.c,v
retrieving revision 1.55
diff -u -p -r1.55 win32-nat.c
--- win32-nat.c 2002/02/22 01:35:59 1.55
+++ win32-nat.c 2002/02/22 16:58:40
@@ -1468,14 +1468,6 @@ child_create_inferior (char *exec_file,
memset (&si, 0, sizeof (si));
si.cb = sizeof (si);
- flags = 0;
-
- if (new_group)
- flags |= CREATE_NEW_PROCESS_GROUP;
-
- if (new_console)
- flags |= CREATE_NEW_CONSOLE;
-
if (!useshell || !shell[0])
{
flags = DEBUG_ONLY_THIS_PROCESS;
@@ -1484,12 +1476,19 @@ child_create_inferior (char *exec_file,
}
else
{
- char *newallargs = alloca (sizeof (" -c 'exec '") + strlen (exec_file)
strlen (allargs) + 2);
+ char *newallargs = alloca (sizeof (" -c 'exec '") + strlen (exec_file)
+ + strlen (allargs) + 2);
sprintf (newallargs, " -c 'exec %s %s'", exec_file, allargs);
allargs = newallargs;
toexec = shell;
flags = DEBUG_PROCESS;
}
+
+ if (new_group)
+ flags |= CREATE_NEW_PROCESS_GROUP;
+
+ if (new_console)
+ flags |= CREATE_NEW_CONSOLE;
args = alloca (strlen (toexec) + strlen (allargs) + 2);
strcpy (args, toexec);
Pierre Muller
Institut Charles Sadron
6,rue Boussingault
F 67083 STRASBOURG CEDEX (France)
mailto:muller@ics.u-strasbg.fr
Phone : (33)-3-88-41-40-07 Fax : (33)-3-88-41-40-99
prev parent reply other threads:[~2002-02-22 17:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-22 0:49 Pierre Muller
2002-02-22 8:25 ` Christopher Faylor
2002-02-22 8:28 ` Christopher Faylor
2002-02-22 9:05 ` Pierre Muller [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4.2.0.58.20020222175830.01a86430@ics.u-strasbg.fr \
--to=muller@cerbere.u-strasbg.fr \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox