From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41333) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YvlFh-0003JP-KY for qemu-devel@nongnu.org; Fri, 22 May 2015 07:36:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YvlFc-0001Px-Pd for qemu-devel@nongnu.org; Fri, 22 May 2015 07:36:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37249) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YvlFc-0001PY-HI for qemu-devel@nongnu.org; Fri, 22 May 2015 07:36:28 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t4MBaRa6017030 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Fri, 22 May 2015 07:36:28 -0400 From: Markus Armbruster Date: Fri, 22 May 2015 13:36:08 +0200 Message-Id: <1432294585-5984-4-git-send-email-armbru@redhat.com> In-Reply-To: <1432294585-5984-1-git-send-email-armbru@redhat.com> References: <1432294585-5984-1-git-send-email-armbru@redhat.com> Subject: [Qemu-devel] [PATCH 03/20] monitor: Improve and document client_migrate_info protocol error List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: lcapitulino@redhat.com Protocol must be spice, vnc isn't implemented. Fix up documentation. Attempts to use vnc or any other unknown protocol yield the misleading error message "Invalid parameter 'protocol'". Improve it to "Parameter 'protocol' expects spice". Signed-off-by: Markus Armbruster --- hmp-commands.hx | 1 + monitor.c | 2 +- qmp-commands.hx | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hmp-commands.hx b/hmp-commands.hx index e864a6c..a8be73a 100644 --- a/hmp-commands.hx +++ b/hmp-commands.hx @@ -1022,6 +1022,7 @@ STEXI Set the spice/vnc connection info for the migration target. The spice/vnc server will ask the spice/vnc client to automatically reconnect using the new parameters (if specified) once the vm migration finished successfully. +Not yet implemented for VNC. ETEXI { diff --git a/monitor.c b/monitor.c index 5330e61..b507ee3 100644 --- a/monitor.c +++ b/monitor.c @@ -1063,7 +1063,7 @@ static int client_migrate_info(Monitor *mon, const QDict *qdict, return 0; } - qerror_report(QERR_INVALID_PARAMETER, "protocol"); + qerror_report(QERR_INVALID_PARAMETER_VALUE, "protocol", "spice"); return -1; } diff --git a/qmp-commands.hx b/qmp-commands.hx index 14e109e..c267c89 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -795,10 +795,11 @@ client_migrate_info Set the spice/vnc connection info for the migration target. The spice/vnc server will ask the spice/vnc client to automatically reconnect using the new parameters (if specified) once the vm migration finished successfully. +Not yet implemented for VNC. Arguments: -- "protocol": protocol: "spice" or "vnc" (json-string) +- "protocol": must be "spice" (json-string) - "hostname": migration target hostname (json-string) - "port": spice/vnc tcp port for plaintext channels (json-int, optional) - "tls-port": spice tcp port for tls-secured channels (json-int, optional) -- 1.9.3