diff options
-rw-r--r-- | gdb/corefile.c | 4 | ||||
-rw-r--r-- | gdb/gdbcore.h | 2 | ||||
-rw-r--r-- | gdb/progspace.h | 3 |
3 files changed, 4 insertions, 5 deletions
diff --git a/gdb/corefile.c b/gdb/corefile.c index 31301cf..a860ce3 100644 --- a/gdb/corefile.c +++ b/gdb/corefile.c @@ -53,10 +53,6 @@ static hook_type *exec_file_extra_hooks; /* Array of additional hooks. */ static int exec_file_hook_count = 0; /* Size of array. */ -/* Binary file diddling handle for the core file. */ - -bfd *core_bfd = NULL; - /* corelow.c target. It is never NULL after GDB initialization. */ struct target_ops *core_target; diff --git a/gdb/gdbcore.h b/gdb/gdbcore.h index 0c08b37..03231e8 100644 --- a/gdb/gdbcore.h +++ b/gdb/gdbcore.h @@ -136,7 +136,7 @@ extern void specify_exec_file_hook (void (*hook) (const char *filename)); /* Binary File Diddler for the core file. */ -extern bfd *core_bfd; +#define core_bfd (current_program_space->cbfd) extern struct target_ops *core_target; diff --git a/gdb/progspace.h b/gdb/progspace.h index 48f206e..cbb3f2b 100644 --- a/gdb/progspace.h +++ b/gdb/progspace.h @@ -206,6 +206,9 @@ struct program_space This is so we can properly report solib changes to the user. */ VEC (char_ptr) *deleted_solibs; + /* Binary file diddling handle for the core file. */ + bfd *cbfd; + /* Per pspace data-pointers required by other GDB modules. */ REGISTRY_FIELDS; }; |