This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [rfa] Assume thread-db loaded over a live process


On Mon, Sep 13, 2004 at 09:57:25AM -0400, Andrew Cagney wrote:
> Hello,
> 
> This patch changes:
> 
> -      /* We can only poke around if there actually is a child process.
> -         If there is no child process alive, postpone the steps below
> -         until one has been created.  */
> -      if (proc_handle.pid != 0)
> -       {
> -         enable_thread_event_reporting ();
> -         thread_db_find_new_threads ();
> -       }
> +      enable_thread_event_reporting ();
> +      thread_db_find_new_threads ();
> 
> this code is only executed when there is a child process so the guard 
> isn't needed.    Tested on GNU/Linux, no change in test results.

Historical note: this code is older than the !target_has_execution
check above.  It used to be reachable, and was for the static
executable case.

Seems a reasonable change to me.

-- 
Daniel Jacobowitz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]