gdb/
Report error on inaccessible memory. * cli/cli-dump.c: Include gdbcore.h. (dump_memory_to_file): Call read_memory instead of target_read_memory. gdb/testsuite/ * gdb.base/dump.exp (inaccessible memory is reported): New test.
This commit is contained in:
parent
e0452928e8
commit
c0ac0ec78d
4 changed files with 17 additions and 2 deletions
|
@ -30,6 +30,7 @@
|
|||
#include <ctype.h>
|
||||
#include "target.h"
|
||||
#include "readline/readline.h"
|
||||
#include "gdbcore.h"
|
||||
|
||||
#define XMALLOC(TYPE) ((TYPE*) xmalloc (sizeof (TYPE)))
|
||||
|
||||
|
@ -246,7 +247,7 @@ dump_memory_to_file (char *cmd, char *mode, char *file_format)
|
|||
value. */
|
||||
buf = xmalloc (count);
|
||||
make_cleanup (xfree, buf);
|
||||
target_read_memory (lo, buf, count);
|
||||
read_memory (lo, buf, count);
|
||||
|
||||
/* Have everything. Open/write the data. */
|
||||
if (file_format == NULL || strcmp (file_format, "binary") == 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue