mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-02-17 13:10:12 +08:00
* breakpoint.c (delete_breakpoint): Fix bpt->val, bpt->exp
storage leaks. (breakpoint_re_set_one): Fix b->exp, b->val, b->cond storage leaks. * infcmd.c (run_command), solib.c (locate_base): Check for target_has_execution in addition to inferior_pid, a core file from a threaded program is yielding a non-zero inferior_pid. * sparc-tdep.c (get_saved_register): Handle window registers in a dummy frame correctly.
This commit is contained in:
parent
6c0643e30f
commit
39ce68291e
@ -1,3 +1,16 @@
|
||||
Sun Apr 28 03:44:30 1996 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
|
||||
|
||||
* breakpoint.c (delete_breakpoint): Fix bpt->val, bpt->exp
|
||||
storage leaks.
|
||||
(breakpoint_re_set_one): Fix b->exp, b->val, b->cond storage leaks.
|
||||
|
||||
* infcmd.c (run_command), solib.c (locate_base): Check for
|
||||
target_has_execution in addition to inferior_pid, a core file
|
||||
from a threaded program is yielding a non-zero inferior_pid.
|
||||
|
||||
* sparc-tdep.c (get_saved_register): Handle window registers
|
||||
in a dummy frame correctly.
|
||||
|
||||
Sat Apr 27 20:38:32 1996 Fred Fish <fnf@cygnus.com>
|
||||
|
||||
* Makefile.in (CLIBS): Move $(MMALLOC) past all other libs,
|
||||
|
@ -1972,6 +1972,8 @@ set_raw_breakpoint (sal)
|
||||
|
||||
static int internal_breakpoint_number = -1;
|
||||
|
||||
#ifdef GET_LONGJMP_TARGET
|
||||
|
||||
static void
|
||||
create_longjmp_breakpoint (func_name)
|
||||
char *func_name;
|
||||
@ -2007,6 +2009,8 @@ create_longjmp_breakpoint (func_name)
|
||||
b->number = internal_breakpoint_number--;
|
||||
}
|
||||
|
||||
#endif /* #ifdef GET_LONGJMP_TARGET */
|
||||
|
||||
/* Call this routine when stepping and nexting to enable a breakpoint if we do
|
||||
a longjmp(). When we hit that breakpoint, call
|
||||
set_longjmp_resume_breakpoint() to figure out where we are going. */
|
||||
@ -3299,8 +3303,12 @@ delete_breakpoint (bpt)
|
||||
free (bpt->cond_string);
|
||||
if (bpt->addr_string != NULL)
|
||||
free (bpt->addr_string);
|
||||
if (bpt->exp != NULL)
|
||||
free (bpt->exp);
|
||||
if (bpt->exp_string != NULL)
|
||||
free (bpt->exp_string);
|
||||
if (bpt->val != NULL)
|
||||
value_free (bpt->val);
|
||||
if (bpt->source_file != NULL)
|
||||
free (bpt->source_file);
|
||||
|
||||
@ -3433,9 +3441,13 @@ breakpoint_re_set_one (bint)
|
||||
particular level, but that's going to be less stable than filenames
|
||||
or functionnames. */
|
||||
/* So for now, just use a global context. */
|
||||
if (b->exp)
|
||||
free ((PTR)b->exp);
|
||||
b->exp = parse_expression (b->exp_string);
|
||||
b->exp_valid_block = innermost_block;
|
||||
mark = value_mark ();
|
||||
if (b->val)
|
||||
value_free (b->val);
|
||||
b->val = evaluate_expression (b->exp);
|
||||
release_value (b->val);
|
||||
if (VALUE_LAZY (b->val))
|
||||
@ -3444,6 +3456,8 @@ breakpoint_re_set_one (bint)
|
||||
if (b->cond_string != NULL)
|
||||
{
|
||||
s = b->cond_string;
|
||||
if (b->cond)
|
||||
free ((PTR)b->cond);
|
||||
b->cond = parse_exp_1 (&s, (struct block *)0, 0);
|
||||
}
|
||||
if (b->enable == enabled)
|
||||
|
@ -187,7 +187,7 @@ run_command (args, from_tty)
|
||||
|
||||
dont_repeat ();
|
||||
|
||||
if (inferior_pid)
|
||||
if (inferior_pid && target_has_execution)
|
||||
{
|
||||
if (
|
||||
!query ("The program being debugged has been started already.\n\
|
||||
@ -1164,10 +1164,9 @@ attach_command (args, from_tty)
|
||||
clear_proceed_status ();
|
||||
stop_soon_quietly = 1;
|
||||
|
||||
#ifndef MACH
|
||||
/* Mach 3 does not generate any traps when attaching to inferior,
|
||||
and to set up frames we can do this. */
|
||||
|
||||
/* No traps are generated when attaching to inferior under Mach 3
|
||||
or GNU hurd. */
|
||||
#ifndef ATTACH_NO_WAIT
|
||||
wait_for_inferior ();
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user