This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 6/8] Handle notification for all-stop.
On 12/11/2012 06:40 AM, Yao Qi wrote:
> @@ -5785,7 +5786,15 @@ remote_wait_as (ptid_t ptid, struct target_waitstatus *status, int options)
> _never_ wait for ever -> test on target_is_async_p().
> However, before we do that we need to ensure that the caller
> knows how to take the target into/out of async mode. */
> - ret = getpkt_sane (&rs->buf, &rs->buf_size, wait_forever_enabled_p);
> + ret = getpkt_or_notif_sane (&rs->buf, &rs->buf_size,
> + wait_forever_enabled_p, &is_notif);
> +
> + if (ret != -1 && is_notif)
> + {
> + /* The target didn't really stop; keep waiting. */
> + rs->waiting_for_stop_reply = 1;
Why do we need to set this here? It's only cleared a bit below?
> + return minus_one_ptid;
> + }
> if (!target_is_async_p ())
> signal (SIGINT, ofunc);
> }
--
Pedro Alves