Bug 18364 - an external SIGCONT can't be ignored and impacts SIGTERM handling
Summary: an external SIGCONT can't be ignored and impacts SIGTERM handling
Status: NEW
Alias: None
Product: gdb
Classification: Unclassified
Component: gdb (show other bugs)
Version: 7.9
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-01 15:26 UTC by Pádraig Brady
Modified: 2015-05-01 15:26 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pádraig Brady 2015-05-01 15:26:46 UTC
I see that gdb has specialized SIGCONT and SIGSTOP handling as per
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff;h=9b224c5e
and bug #17024

It's impacting my use case where I'm scripting gdb and wrapping with the timeout(1) command. The timeout command will send a SIGCONT in case
the command it's monitoring (gdb in this case) is stopped.
I thought I might be able to get gdb to just ignore this signal with
"handle SIGCONT nostop noprint nopass", but even with that
_intermittently_ gdb will fail to stop a running process when it
receives a SIGTERM and SIGCONT. Note when in this state, sending
any signal to the process that gdb is running, will cause that
process to exit and then unlock gdb.