* breakpoint.c (decref_bp_location): Assert the reference count is
sane.
This commit is contained in:
parent
f431efe540
commit
0807b50c1a
2 changed files with 9 additions and 0 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2010-08-17 Pedro Alves <pedro@codesourcery.com>
|
||||||
|
|
||||||
|
PR breakpoints/11371
|
||||||
|
|
||||||
|
* breakpoint.c (decref_bp_location): Assert the reference count is
|
||||||
|
sane.
|
||||||
|
|
||||||
2010-08-17 Pedro Alves <pedro@codesourcery.com>
|
2010-08-17 Pedro Alves <pedro@codesourcery.com>
|
||||||
|
|
||||||
PR breakpoints/11371
|
PR breakpoints/11371
|
||||||
|
|
|
@ -5423,6 +5423,8 @@ incref_bp_location (struct bp_location *bl)
|
||||||
static void
|
static void
|
||||||
decref_bp_location (struct bp_location **blp)
|
decref_bp_location (struct bp_location **blp)
|
||||||
{
|
{
|
||||||
|
gdb_assert ((*blp)->refc > 0);
|
||||||
|
|
||||||
if (--(*blp)->refc == 0)
|
if (--(*blp)->refc == 0)
|
||||||
free_bp_location (*blp);
|
free_bp_location (*blp);
|
||||||
*blp = NULL;
|
*blp = NULL;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue