diff options
author | Luiz Capitulino <lcapitulino@redhat.com> | 2009-08-28 15:27:13 -0300 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-09-04 09:37:31 -0500 |
commit | d54908a55b9123b11c6d525f022f92bb016a6468 (patch) | |
tree | c6305d08a2f82fe375e4d01eaa35d9b03c0b2a80 /savevm.c | |
parent | f96fc8a0f10e30bc193c27ca6ea6f9ed975e77b2 (diff) |
monitor: Port handler_1 to use QDict
This commit ports command handlers that receive one argument to use
the new monitor's dictionary.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'savevm.c')
-rw-r--r-- | savevm.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -1480,7 +1480,7 @@ static int bdrv_snapshot_find(BlockDriverState *bs, QEMUSnapshotInfo *sn_info, return ret; } -void do_savevm(Monitor *mon, const char *name) +void do_savevm(Monitor *mon, const QDict *qdict) { DriveInfo *dinfo; BlockDriverState *bs, *bs1; @@ -1494,6 +1494,7 @@ void do_savevm(Monitor *mon, const char *name) #else struct timeval tv; #endif + const char *name = qdict_get_try_str(qdict, "name"); bs = get_bs_snapshots(); if (!bs) { @@ -1644,11 +1645,12 @@ int load_vmstate(Monitor *mon, const char *name) return 0; } -void do_delvm(Monitor *mon, const char *name) +void do_delvm(Monitor *mon, const QDict *qdict) { DriveInfo *dinfo; BlockDriverState *bs, *bs1; int ret; + const char *name = qdict_get_str(qdict, "name"); bs = get_bs_snapshots(); if (!bs) { |