From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57271) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WwxMc-0006r8-Fe for qemu-devel@nongnu.org; Tue, 17 Jun 2014 13:40:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WwxMW-0004UU-Bc for qemu-devel@nongnu.org; Tue, 17 Jun 2014 13:40:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:57603) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WwxMW-0004U6-3P for qemu-devel@nongnu.org; Tue, 17 Jun 2014 13:40:00 -0400 Date: Tue, 17 Jun 2014 20:40:23 +0300 From: "Michael S. Tsirkin" Message-ID: <1403021756-15960-69-git-send-email-mst@redhat.com> References: <1403021756-15960-1-git-send-email-mst@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1403021756-15960-1-git-send-email-mst@redhat.com> Subject: [Qemu-devel] [PULL 068/103] qmp: improve error reporting for -object and object-add List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Maydell , Luiz Capitulino , Hu Tao , Anthony Liguori , Paolo Bonzini From: Paolo Bonzini Use QERR_INVALID_PARAMETER_VALUE for consistency. Signed-off-by: Paolo Bonzini Signed-off-by: Hu Tao Acked-by: Michael S. Tsirkin --- qmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qmp.c b/qmp.c index b722dbe..c3c0229 100644 --- a/qmp.c +++ b/qmp.c @@ -540,7 +540,7 @@ void object_add(const char *type, const char *id, const QDict *qdict, klass = object_class_by_name(type); if (!klass) { - error_setg(errp, "invalid class name"); + error_setg(errp, "invalid object type: %s", type); return; } -- MST