[RFA] Checkpoint: wait the defunct process when delete it
Michael Snyder
msnyder@vmware.com
Wed May 12 00:27:00 GMT 2010
Pedro Alves wrote:
> On Tuesday 11 May 2010 23:43:04, Michael Snyder wrote:
>
>
>> old_cleanup = save_inferior_ptid ();
>> inferior_ptid = fd->parent_ptid;
>>
>> Something like this? Then the original inferior_ptid will be
>> restored when you do
>>
>>> + if (call_function_by_hand (waitpid_fn, 3, argv) == 0)
>>> + return -1;
>> do_cleanups();
>>
>>> + return 0;
>>> +}
>
> That won't work. You will hit an assertion somewhere: either because
> inferior_ptid is not found in the linux-nat.c lwp list, or because
> inferior_ptid is not found in gdb's thread list. I believe you'll
> need to do a full linux_nat_switch_fork and back.
>
There you go. ;-)
More information about the Gdb-patches
mailing list