aboutsummaryrefslogtreecommitdiff
path: root/gdb/remote.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/remote.c')
-rw-r--r--gdb/remote.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/gdb/remote.c b/gdb/remote.c
index 9ee1e8c..291b7c6 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -56,7 +56,7 @@
#include <signal.h>
#include "serial.h"
-#include "gdbcore.h" /* for exec_bfd */
+#include "gdbcore.h"
#include "remote-fileio.h"
#include "gdb/fileio.h"
@@ -10770,7 +10770,7 @@ compare_sections_command (const char *args, int from_tty)
int res;
int read_only = 0;
- if (!exec_bfd)
+ if (!current_program_space->exec_bfd ())
error (_("command cannot be used without an exec file"));
if (args != NULL && strcmp (args, "-r") == 0)
@@ -10779,7 +10779,7 @@ compare_sections_command (const char *args, int from_tty)
args = NULL;
}
- for (s = exec_bfd->sections; s; s = s->next)
+ for (s = current_program_space->exec_bfd ()->sections; s; s = s->next)
{
if (!(s->flags & SEC_LOAD))
continue; /* Skip non-loadable section. */
@@ -10799,7 +10799,8 @@ compare_sections_command (const char *args, int from_tty)
lma = s->lma;
gdb::byte_vector sectdata (size);
- bfd_get_section_contents (exec_bfd, s, sectdata.data (), 0, size);
+ bfd_get_section_contents (current_program_space->exec_bfd (), s,
+ sectdata.data (), 0, size);
res = target_verify_memory (sectdata.data (), lma, size);
@@ -13180,14 +13181,14 @@ remote_target::trace_set_readonly_regions ()
int anysecs = 0;
int offset = 0;
- if (!exec_bfd)
+ if (!current_program_space->exec_bfd ())
return; /* No information to give. */
struct remote_state *rs = get_remote_state ();
strcpy (rs->buf.data (), "QTro");
offset = strlen (rs->buf.data ());
- for (s = exec_bfd->sections; s; s = s->next)
+ for (s = current_program_space->exec_bfd ()->sections; s; s = s->next)
{
char tmp1[40], tmp2[40];
int sec_length;