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 /vl.c | |
parent | f96fc8a0f10e30bc193c27ca6ea6f9ed975e77b2 (diff) | |
download | hqemu-d54908a55b9123b11c6d525f022f92bb016a6468.zip hqemu-d54908a55b9123b11c6d525f022f92bb016a6468.tar.gz |
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 'vl.c')
-rw-r--r-- | vl.c | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -479,10 +479,11 @@ void do_info_mice(Monitor *mon) } } -void do_mouse_set(Monitor *mon, int index) +void do_mouse_set(Monitor *mon, const QDict *qdict) { QEMUPutMouseEntry *cursor; int i = 0; + int index = qdict_get_int(qdict, "index"); if (!qemu_put_mouse_event_head) { monitor_printf(mon, "No mouse devices connected\n"); @@ -2597,14 +2598,14 @@ static int usb_parse(const char *cmdline) return usb_device_add(cmdline, 0); } -void do_usb_add(Monitor *mon, const char *devname) +void do_usb_add(Monitor *mon, const QDict *qdict) { - usb_device_add(devname, 1); + usb_device_add(qdict_get_str(qdict, "devname"), 1); } -void do_usb_del(Monitor *mon, const char *devname) +void do_usb_del(Monitor *mon, const QDict *qdict) { - usb_device_del(devname); + usb_device_del(qdict_get_str(qdict, "devname")); } void usb_info(Monitor *mon) |