* [ob] No need to restore shadows if we haven't read anything.
@ 2011-01-28 16:01 Pedro Alves
0 siblings, 0 replies; only message in thread
From: Pedro Alves @ 2011-01-28 16:01 UTC (permalink / raw)
To: gdb-patches
Applied.
--
Pedro Alves
2011-01-28 Pedro Alves <pedro@codesourcery.com>
gdb/
* target.c (memory_xfer_partial): No need to restore shadows if we
haven't read anything.
---
gdb/target.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: src/gdb/target.c
===================================================================
--- src.orig/gdb/target.c 2011-01-19 18:26:47.371219996 +0000
+++ src/gdb/target.c 2011-01-28 15:55:11.697137000 +0000
@@ -1414,7 +1414,7 @@ memory_xfer_partial (struct target_ops *
}
while (ops != NULL);
- if (readbuf && !show_memory_breakpoints)
+ if (res > 0 && readbuf != NULL && !show_memory_breakpoints)
breakpoint_restore_shadows (readbuf, memaddr, reg_len);
/* Make sure the cache gets updated no matter what - if we are writing
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-01-28 16:01 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-28 16:01 [ob] No need to restore shadows if we haven't read anything Pedro Alves
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).