Patchwork [5/7] monitor: Convert do_stop() to QObject

login
register
mail settings
Submitter Luiz Capitulino
Date Sept. 16, 2009, 9:32 p.m.
Message ID <1253136760-3614-6-git-send-email-lcapitulino@redhat.com>
Download mbox | patch
Permalink /patch/33747/
State Superseded
Headers show

Comments

Luiz Capitulino - Sept. 16, 2009, 9:32 p.m.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 monitor.c       |    8 +++++++-
 qemu-monitor.hx |    2 +-
 2 files changed, 8 insertions(+), 2 deletions(-)

Patch

diff --git a/monitor.c b/monitor.c
index b324538..9ef9108 100644
--- a/monitor.c
+++ b/monitor.c
@@ -604,9 +604,15 @@  static void do_singlestep(Monitor *mon, const QDict *qdict)
     }
 }
 
-static void do_stop(Monitor *mon, const QDict *qdict)
+/**
+ * do_stop(): Stop VM execution
+ *
+ * return always succeed.
+ */
+static int do_stop(Monitor *mon, const QDict *qdict, QObject **ret_data)
 {
     vm_stop(EXCP_INTERRUPT);
+    return 0;
 }
 
 static void encrypted_bdrv_it(void *opaque, BlockDriverState *bs);
diff --git a/qemu-monitor.hx b/qemu-monitor.hx
index 401d5c5..f6c9911 100644
--- a/qemu-monitor.hx
+++ b/qemu-monitor.hx
@@ -285,7 +285,7 @@  ETEXI
         .name       = "stop",
         .args_type  = "",
         .handler    = do_stop,
-        .user_print = NULL,
+        .user_print = monitor_print_nothing,
         .params     = "",
         .help       = "stop emulation",
     },