From: Jan Kratochvil Date: Fri, 20 Jan 2012 20:02:25 +0000 (+0000) Subject: gdb/gdbserver/ X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e825046fcf0193aad44b1f3d1a8514190278b85d;p=binutils-gdb.git gdb/gdbserver/ Code cleanup. * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid. --- diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index 0cb67da17b4..dfc5cdd8804 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2012-01-20 Jan Kratochvil + + Code cleanup. + * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid. + 2012-01-20 Ulrich Weigand * hostio.c (handle_readlink): New function. diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c index eb21e142095..653518046a2 100644 --- a/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c @@ -1578,8 +1578,7 @@ linux_wait_for_event_1 (ptid_t ptid, int *wstat, int options) /* Check for a lwp with a pending status. */ - if (ptid_equal (ptid, minus_one_ptid) - || ptid_equal (pid_to_ptid (ptid_get_pid (ptid)), ptid)) + if (ptid_equal (ptid, minus_one_ptid) || ptid_is_pid (ptid)) { event_child = (struct lwp_info *) find_inferior (&all_lwps, status_pending_p_callback, &ptid);