Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <pedro@codesourcery.com>
To: Yao Qi <yao@codesourcery.com>
Cc: gdb-patches@sourceware.org, Tom Tromey <tromey@redhat.com>
Subject: Re: [rfc] Call init_wait_for_inferior before get_offsets
Date: Thu, 23 Jun 2011 13:46:00 -0000	[thread overview]
Message-ID: <201106231446.20827.pedro@codesourcery.com> (raw)
In-Reply-To: <4E033D7F.6090000@codesourcery.com>

On Thursday 23 June 2011 14:19:59, Yao Qi wrote:
> On 06/23/2011 06:38 PM, Pedro Alves wrote:
> > On Thursday 23 June 2011 11:34:41, Yao Qi wrote:
> > 
> >>> Yao> 	* remote.c (remote_start_remote): ... here.
> > 
> > There's another call to get_offsets in the else branch.
> > 
> 
> Yes, but there has been a call to init_wait_for_inferior () "guarded" at
> the beginning of that branch.

Bah, and I was the one that put it there even... :-)

> 
>   else
>     {
>       /* Clear WFI global state.  Do this before finding about new
> 	 threads and inferiors, and setting the current inferior.
> 	 Otherwise we would clear the proceed status of the current
> 	 inferior when we want its stop_soon state to be preserved
> 	 (see notice_new_inferior).  */
>       init_wait_for_inferior ();
> ...
> ...
>       get_offsets ();		/* Get text, data & bss offsets.  */

Your patch is okay ...

> +      init_wait_for_inferior ();
> +
>        get_offsets ();          /* Get text, data & bss offsets.  */

... with a small comment above the init_wait_for_inferior call
mentioning the reason it is called before get_offsets.

-- 
Pedro Alves


  reply	other threads:[~2011-06-23 13:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-20  5:12 Yao Qi
2011-06-22 15:08 ` Tom Tromey
2011-06-23 10:35   ` Yao Qi
2011-06-23 10:39     ` Pedro Alves
2011-06-23 13:20       ` Yao Qi
2011-06-23 13:46         ` Pedro Alves [this message]
2011-06-23 15:09           ` [committed] " Yao Qi

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=201106231446.20827.pedro@codesourcery.com \
    --to=pedro@codesourcery.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@redhat.com \
    --cc=yao@codesourcery.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