Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Chris January <chris.january@allinea.com>, gdb@sourceware.org
Subject: Re: catch signal does not appear multi-inferior safe
Date: Tue, 19 Aug 2014 15:37:00 -0000	[thread overview]
Message-ID: <53F36F39.8090201@redhat.com> (raw)
In-Reply-To: <1405076204.3524.8.camel@chris-xps13>

On 07/11/2014 11:56 AM, Chris January wrote:
> Hello,
> 
> It appears to me that the 'catch signal' support in GDB is not
> multi-inferior safe. Combining the 'catch signal' command with the
> 'checkpoint' command, for example, results in an internal error:
> 
> break-catch-sig.c:152: internal-error:
> signal_catchpoint_remove_location: Assertion `signal_catch_counts[iter]
>> 0' failed.
> A problem internal to GDB has been detected,
> further debugging may prove unreliable.
> Quit this debugging session? (y or n)
> 
> see the end of this e-mail for reproducer.
> 
> When checkpointing / catching a fork signal_catchpoint_remove_location
> may be called twice in a row - once for the parent and once for the
> child. 

Signal catchpoint locations aren't really per-process; they're
global.  GDB shouldn't be trying to detach them from the child.
Where is this happening?  Is this from detach_breakpoint ?  That's
odd, since that skips bp_loc_other locations?

> This causes signal_catch_counts to go below 0. I would like some
> advice on how to fix this problem as I am not sure what the correct fix
> is.


-- 
Thanks,
Pedro Alves


  reply	other threads:[~2014-08-19 15:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-11 10:56 Chris January
2014-08-19 15:37 ` Pedro Alves [this message]
2014-08-28 10:58   ` Chris January

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=53F36F39.8090201@redhat.com \
    --to=palves@redhat.com \
    --cc=chris.january@allinea.com \
    --cc=gdb@sourceware.org \
    /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