aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2004-01-31 18:14:08 +0000
committerDaniel Jacobowitz <drow@false.org>2004-01-31 18:14:08 +0000
commitfad0733a64e6fe0c4931c183e5ca13631f9272d7 (patch)
treef1ba34604ce9261e1ff67b5ea9a15bb573e0e6cb /gdb
parentabbab9d3eb9d08598e0dfff05a437fbb63074d3b (diff)
downloadgdb-fad0733a64e6fe0c4931c183e5ca13631f9272d7.zip
gdb-fad0733a64e6fe0c4931c183e5ca13631f9272d7.tar.gz
gdb-fad0733a64e6fe0c4931c183e5ca13631f9272d7.tar.bz2
* breakpoint.c (breakpoint_re_set_one): Add missing chunk of
2004-01-27 double-free fix.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/breakpoint.c7
2 files changed, 11 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 720dc80..3e5dead 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2004-01-31 Daniel Jacobowitz <drow@mvista.com>
+
+ * breakpoint.c (breakpoint_re_set_one): Add missing chunk of
+ 2004-01-27 double-free fix.
+
2004-01-31 Mark Kettenis <kettenis@gnu.org>
* sparc-tdep.c (sparc_fetch_wcookie): New function.
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
index a9bd979..4ea0f67 100644
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -6902,7 +6902,12 @@ breakpoint_re_set_one (void *bint)
{
s = b->cond_string;
if (b->cond)
- xfree (b->cond);
+ {
+ xfree (b->cond);
+ /* Avoid re-freeing b->exp if an error during the call
+ to parse_exp_1. */
+ b->cond = NULL;
+ }
b->cond = parse_exp_1 (&s, block_for_pc (sals.sals[i].pc), 0);
}