qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Fix crash on 'info vnc' after 'change vnc none'
@ 2008-11-12 18:38 James Ko
  2008-11-13 19:53 ` Anthony Liguori
  2008-12-13 18:58 ` Aurelien Jarno
  0 siblings, 2 replies; 3+ messages in thread
From: James Ko @ 2008-11-12 18:38 UTC (permalink / raw)
  To: qemu-devel

I propose the following patch to prevent crash in call to term_print_filename
with NULL vnc_state->display argument from do_info_vnc.

vnc_state->display is set to NULL after "change vnc none" but vnc_state itself
is still valid.

James

diff -aru a/qemu/vnc.c b/qemu/vnc.c
--- a/qemu/vnc.c  2008-08-21 17:46:40.000000000 -0700
+++ b/qemu/vnc.c  2008-11-06 14:31:51.000000000 -0800
@@ -180,7 +180,7 @@

  void do_info_vnc(void)
  {
-    if (vnc_state == NULL)
+    if (vnc_state == NULL || vnc_state->display == NULL)
  	term_printf("VNC server disabled\n");
      else {
  	term_printf("VNC server active on: ");

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

end of thread, other threads:[~2008-12-13 18:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-12 18:38 [Qemu-devel] [PATCH] Fix crash on 'info vnc' after 'change vnc none' James Ko
2008-11-13 19:53 ` Anthony Liguori
2008-12-13 18:58 ` Aurelien Jarno

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).