qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] PowerPC: Avoid segfault in cpu_dump_state
@ 2012-05-14 14:46 Fabien Chouteau
  2012-05-14 15:39 ` Peter Maydell
  0 siblings, 1 reply; 12+ messages in thread
From: Fabien Chouteau @ 2012-05-14 14:46 UTC (permalink / raw)
  To: qemu-devel; +Cc: qemu-ppc, agraf

Quit if no log file is defined.

Signed-off-by: Fabien Chouteau <chouteau@adacore.com>
---
 target-ppc/translate.c |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/target-ppc/translate.c b/target-ppc/translate.c
index cf59765..f17bd91 100644
--- a/target-ppc/translate.c
+++ b/target-ppc/translate.c
@@ -9319,6 +9319,10 @@ void cpu_dump_state (CPUPPCState *env, FILE *f, fprintf_function cpu_fprintf,
 
     int i;
 
+    if (f == NULL) {
+        return;
+    }
+
     cpu_synchronize_state(env);
 
     cpu_fprintf(f, "NIP " TARGET_FMT_lx "   LR " TARGET_FMT_lx " CTR "
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2012-05-23 15:44 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-14 14:46 [Qemu-devel] [PATCH] PowerPC: Avoid segfault in cpu_dump_state Fabien Chouteau
2012-05-14 15:39 ` Peter Maydell
2012-05-15  9:39   ` [Qemu-devel] [PATCH] " Fabien Chouteau
2012-05-15 13:31     ` Andreas Färber
2012-05-15 16:08       ` Fabien Chouteau
2012-05-15 16:20         ` Peter Maydell
2012-05-15 16:45           ` Fabien Chouteau
2012-05-15 18:04             ` Peter Maydell
2012-05-16  3:50         ` Andreas Färber
2012-05-16  8:29           ` Fabien Chouteau
2012-05-16 13:39             ` Fabien Chouteau
2012-05-23 15:43               ` Fabien Chouteau

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 NNTP newsgroup(s).