This is the mail archive of the gdb@sourceware.org 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: linux-low.c: stop_all_processes vs longjmp snafu?


On Fri, Dec 12, 2008 at 4:13 PM, Doug Evans <dje@google.com> wrote:
> linux-low.c:stop_all_processes is the only place that sets stopping_threads:
>
> static void
> stop_all_processes (void)
> {
>  stopping_threads = 1;
>  for_each_inferior (&all_processes, send_sigstop);
>  for_each_inferior (&all_processes, wait_for_sigstop);
>  stopping_threads = 0;
> }
>
> and all functions that test stopping_threads can throw an error
> (call longjmp).
>
> I'm guessing fixing this is waiting on someone to remove stopping_threads,
> right?

I was thinking that we don't want to support nested setjmps.  But in a
case like this do we want to continue to try to stop all processes
even if stopping one of them throws an error?  [assuming we're keeping
setjmp and not rewriting gdbserver in c++ ...]


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