Patchwork [3/9] monitor: Convert do_migrate() to QObject

login
register
mail settings
Submitter Luiz Capitulino
Date Oct. 16, 2009, 3:23 p.m.
Message ID <1255706631-3742-4-git-send-email-lcapitulino@redhat.com>
Download mbox | patch
Permalink /patch/36239/
State New
Headers show

Comments

Luiz Capitulino - Oct. 16, 2009, 3:23 p.m.
Error is still directly printed, as we are only converting
regular output.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 migration.c     |    2 +-
 migration.h     |    2 +-
 qemu-monitor.hx |    3 ++-
 3 files changed, 4 insertions(+), 3 deletions(-)

Patch

diff --git a/migration.c b/migration.c
index 7f93e3f..fb37d1b 100644
--- a/migration.c
+++ b/migration.c
@@ -52,7 +52,7 @@  void qemu_start_incoming_migration(const char *uri)
         fprintf(stderr, "unknown migration protocol: %s\n", uri);
 }
 
-void do_migrate(Monitor *mon, const QDict *qdict)
+void do_migrate(Monitor *mon, const QDict *qdict, QObject **ret_data)
 {
     MigrationState *s = NULL;
     const char *p;
diff --git a/migration.h b/migration.h
index 53b923d..17ca9ff 100644
--- a/migration.h
+++ b/migration.h
@@ -50,7 +50,7 @@  struct FdMigrationState
 
 void qemu_start_incoming_migration(const char *uri);
 
-void do_migrate(Monitor *mon, const QDict *qdict);
+void do_migrate(Monitor *mon, const QDict *qdict, QObject **ret_data);
 
 void do_migrate_cancel(Monitor *mon, const QDict *qdict);
 
diff --git a/qemu-monitor.hx b/qemu-monitor.hx
index 1c605bd..8e7bfd4 100644
--- a/qemu-monitor.hx
+++ b/qemu-monitor.hx
@@ -726,7 +726,8 @@  ETEXI
         .args_type  = "detach:-d,uri:s",
         .params     = "[-d] uri",
         .help       = "migrate to URI (using -d to not wait for completion)",
-        .mhandler.cmd = do_migrate,
+        .user_print = monitor_user_noop,
+        .mhandler.cmd_new = do_migrate,
     },
 
 STEXI