return lp->ptid.pid () == lp->ptid.lwp ();
}
+/* Convert an LWP's pending status to a std::string. */
+
+static std::string
+pending_status_str (lwp_info *lp)
+{
+ gdb_assert (lwp_status_pending_p (lp));
+
+ if (lp->waitstatus.kind () != TARGET_WAITKIND_IGNORE)
+ return lp->waitstatus.to_string ();
+ else
+ return status_to_str (lp->status);
+}
+
\f
/* LWP accessors. */
this thread with a signal? */
gdb_assert (signo == GDB_SIGNAL_0);
- linux_nat_debug_printf ("Short circuiting for status 0x%x",
- lp->status);
+ linux_nat_debug_printf ("Short circuiting for status %s",
+ pending_status_str (lp).c_str ());
if (target_can_async_p ())
{
if (lp != NULL)
{
linux_nat_debug_printf ("Using pending wait status %s for %s.",
- status_to_str (lp->status).c_str (),
+ pending_status_str (lp).c_str (),
lp->ptid.to_string ().c_str ());
}