aboutsummaryrefslogtreecommitdiff
path: root/gdb/target.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2013-12-18 14:55:44 -0700
committerTom Tromey <tromey@redhat.com>2014-02-19 07:48:19 -0700
commiteb276a6b5b56eeb15729892d66d11782bbacbdfc (patch)
tree6bc3bfb201dadb21012c86ff50f9f087e0e2190a /gdb/target.c
parent9e538d0d0bebe3230940a820c6ec1016f0795899 (diff)
downloadgdb-eb276a6b5b56eeb15729892d66d11782bbacbdfc.zip
gdb-eb276a6b5b56eeb15729892d66d11782bbacbdfc.tar.gz
gdb-eb276a6b5b56eeb15729892d66d11782bbacbdfc.tar.bz2
convert to_verify_memory
2014-02-19 Tom Tromey <tromey@redhat.com> * target-delegates.c: Rebuild. * target.c (target_verify_memory): Unconditionally delegate. * target.h (struct target_ops) <to_verify_memory>: Use TARGET_DEFAULT_NORETURN.
Diffstat (limited to 'gdb/target.c')
-rw-r--r--gdb/target.c27
1 files changed, 9 insertions, 18 deletions
diff --git a/gdb/target.c b/gdb/target.c
index 5f86c4e..4468648 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -3723,25 +3723,16 @@ target_core_of_thread (ptid_t ptid)
int
target_verify_memory (const gdb_byte *data, CORE_ADDR memaddr, ULONGEST size)
{
- struct target_ops *t;
-
- for (t = current_target.beneath; t != NULL; t = t->beneath)
- {
- if (t->to_verify_memory != NULL)
- {
- int retval = t->to_verify_memory (t, data, memaddr, size);
+ int retval = current_target.to_verify_memory (&current_target,
+ data, memaddr, size);
- if (targetdebug)
- fprintf_unfiltered (gdb_stdlog,
- "target_verify_memory (%s, %s) = %d\n",
- paddress (target_gdbarch (), memaddr),
- pulongest (size),
- retval);
- return retval;
- }
- }
-
- tcomplain ();
+ if (targetdebug)
+ fprintf_unfiltered (gdb_stdlog,
+ "target_verify_memory (%s, %s) = %d\n",
+ paddress (target_gdbarch (), memaddr),
+ pulongest (size),
+ retval);
+ return retval;
}
/* The documentation for this function is in its prototype declaration in