From 8d7e84571bd3f44c106ed12cb316b1ca30915fc7 Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Wed, 16 Jun 2010 00:38:45 +0200 Subject: [PATCH] QMP: Teach basic capability negotiation to python example As sending "qmp_capabilities" on session start became mandatory, both python examples were broken. Signed-off-by: Jan Kiszka Signed-off-by: Luiz Capitulino --- QMP/qmp-shell | 1 + QMP/vm-info | 1 + 2 files changed, 2 insertions(+) diff --git a/QMP/qmp-shell b/QMP/qmp-shell index f89b9af87e..a5b72d15d1 100755 --- a/QMP/qmp-shell +++ b/QMP/qmp-shell @@ -42,6 +42,7 @@ def main(): qemu = qmp.QEMUMonitorProtocol(argv[1]) qemu.connect() + qemu.send("qmp_capabilities") print 'Connected!' diff --git a/QMP/vm-info b/QMP/vm-info index 8ebaeb38c0..be5b03843c 100755 --- a/QMP/vm-info +++ b/QMP/vm-info @@ -24,6 +24,7 @@ def main(): qemu = qmp.QEMUMonitorProtocol(argv[1]) qemu.connect() + qemu.send("qmp_capabilities") for cmd in [ 'version', 'kvm', 'status', 'uuid', 'balloon' ]: print cmd + ': ' + str(qemu.send('query-' + cmd)) -- GitLab