From: dje@google.com (Doug Evans)
To: gdb-patches@sourceware.org
Subject: [RFA] linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
Date: Fri, 12 Dec 2008 20:01:00 -0000 [thread overview]
Message-ID: <20081212200022.A4E261C7A0E@localhost> (raw)
Hi.
Minor bit of cleanup. Ok to check in?
BTW, there are other calls to waitpid in linux-low.c that don't go through
my_waitpid. Should they use my_waitpid too?
2008-12-12 Doug Evans <dje@google.com>
* linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
Index: linux-low.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbserver/linux-low.c,v
retrieving revision 1.82
diff -u -p -r1.82 linux-low.c
--- linux-low.c 2 Dec 2008 07:57:37 -0000 1.82
+++ linux-low.c 12 Dec 2008 19:57:51 -0000
@@ -121,6 +121,7 @@ static void stop_all_processes (void);
static int linux_wait_for_event (struct thread_info *child);
static int check_removed_breakpoint (struct process_info *event_child);
static void *add_process (unsigned long pid);
+static int my_waitpid (int pid, int *status, int flags);
struct pending_signals
{
@@ -161,9 +162,7 @@ handle_extended_wait (struct process_inf
/* The new child has a pending SIGSTOP. We can't affect it until it
hits the SIGSTOP, but we're already attached. */
- do {
- ret = waitpid (new_pid, &status, __WALL);
- } while (ret == -1 && errno == EINTR);
+ ret = my_waitpid (new_pid, &status, __WALL);
if (ret == -1)
perror_with_name ("waiting for new child");
next reply other threads:[~2008-12-12 20:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-12 20:01 Doug Evans [this message]
2008-12-12 20:46 ` Daniel Jacobowitz
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=20081212200022.A4E261C7A0E@localhost \
--to=dje@google.com \
--cc=gdb-patches@sourceware.org \
/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