From: Daniel Jacobowitz Date: Wed, 12 Nov 2003 17:00:42 +0000 (+0000) Subject: PR breakpoints/1450 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1640b8210df6a1a8d4a7d1d487c9bc88bae1122d;p=binutils-gdb.git PR breakpoints/1450 * breakpoint.c (insert_bp_location): Fix a logic error by returning 0 after a catchpoint fails. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index b185824aae6..5e32d494800 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2003-11-12 Daniel Jacobowitz + + PR breakpoints/1450 + * breakpoint.c (insert_bp_location): Fix a logic error by returning + 0 after a catchpoint fails. + 2003-11-11 Michael Chastain * mips-tdep.c (msymbol_size): Delete. diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 86d9f174232..0e95e208cc3 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -1071,7 +1071,11 @@ insert_bp_location (struct bp_location *bpt, bpt->owner->enable_state = bp_disabled; else bpt->inserted = 1; - return val; + + /* We've already printed an error message if there was a problem + inserting this catchpoint, and we've disabled the catchpoint, + so just return success. */ + return 0; } return 0;