aboutsummaryrefslogtreecommitdiff
path: root/gdb/infrun.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2012-02-16 21:07:20 +0000
committerTom Tromey <tromey@redhat.com>2012-02-16 21:07:20 +0000
commit7dcd53a07458941ccf02e280b42f9d68dfb976b0 (patch)
treed8826dcdbcc1399f5700f571362fc3c257455006 /gdb/infrun.c
parent7b5de7eeacf1f08bc31562510bab508ebcaae3ee (diff)
downloadgdb-7dcd53a07458941ccf02e280b42f9d68dfb976b0.zip
gdb-7dcd53a07458941ccf02e280b42f9d68dfb976b0.tar.gz
gdb-7dcd53a07458941ccf02e280b42f9d68dfb976b0.tar.bz2
* symfile.c (symbol_file_add_main_1): Use inferior's
symfile_flags. * solib.c (solib_read_symbols): Use inferior's symfile_flags. * linux-nat.c (linux_child_follow_fork): Set symfile_flags on inferior. * infrun.c (handle_vfork_child_exec_or_exit): Set symfile_flags on inferior. (follow_exec): Use inferior's symfile_flags. * inferior.h (struct inferior) <symfile_flags>: New field.
Diffstat (limited to 'gdb/infrun.c')
-rw-r--r--gdb/infrun.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/gdb/infrun.c b/gdb/infrun.c
index d3dab9a..1b2da67 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -739,6 +739,7 @@ handle_vfork_child_exec_or_exit (int exec)
pspace = add_program_space (maybe_new_address_space ());
set_current_program_space (pspace);
inf->removable = 1;
+ inf->symfile_flags = SYMFILE_NO_READ;
clone_program_space (pspace, inf->vfork_parent->pspace);
inf->pspace = pspace;
inf->aspace = pspace->aspace;
@@ -900,10 +901,13 @@ follow_exec (ptid_t pid, char *execd_pathname)
solib_create_inferior_hook below. breakpoint_re_set would fail to insert
the breakpoints with the zero displacement. */
- symbol_file_add (execd_pathname, SYMFILE_MAINLINE | SYMFILE_DEFER_BP_RESET,
+ symbol_file_add (execd_pathname,
+ (inf->symfile_flags
+ | SYMFILE_MAINLINE | SYMFILE_DEFER_BP_RESET),
NULL, 0);
- set_initial_language ();
+ if ((inf->symfile_flags & SYMFILE_NO_READ) == 0)
+ set_initial_language ();
#ifdef SOLIB_CREATE_INFERIOR_HOOK
SOLIB_CREATE_INFERIOR_HOOK (PIDGET (inferior_ptid));