From patchwork Mon May 21 17:41:53 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luiz Capitulino X-Patchwork-Id: 160449 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id F1213B6FB9 for ; Tue, 22 May 2012 05:54:20 +1000 (EST) Received: from localhost ([::1]:57320 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SWXd0-0001L4-W7 for incoming@patchwork.ozlabs.org; Mon, 21 May 2012 14:46:46 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41543) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SWXcR-0008IO-Aa for qemu-devel@nongnu.org; Mon, 21 May 2012 14:46:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SWXcP-0003RA-Cd for qemu-devel@nongnu.org; Mon, 21 May 2012 14:46:10 -0400 Received: from mx1.redhat.com ([209.132.183.28]:48258) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SWXcP-0003Py-42 for qemu-devel@nongnu.org; Mon, 21 May 2012 14:46:09 -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 q4LIjqdv017430 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 21 May 2012 14:46:06 -0400 Received: from localhost (ovpn-116-87.ams2.redhat.com [10.36.116.87]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q4LHgJjA029208; Mon, 21 May 2012 13:42:20 -0400 From: Luiz Capitulino To: qemu-devel@nongnu.org Date: Mon, 21 May 2012 14:41:53 -0300 Message-Id: <1337622119-8416-11-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1337622119-8416-1-git-send-email-lcapitulino@redhat.com> References: <1337622119-8416-1-git-send-email-lcapitulino@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.132.183.28 Cc: pbonzini@redhat.com, aliguori@us.ibm.com, lersek@redhat.com, mdroth@linux.vnet.ibm.com, armbru@redhat.com Subject: [Qemu-devel] [PATCH 10/16] qerror: introduce QERR_INVALID_OPTION_GROUP X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Luiz Capitulino --- qerror.c | 4 ++++ qerror.h | 3 +++ 2 files changed, 7 insertions(+) diff --git a/qerror.c b/qerror.c index 5092fe7..92c4eff 100644 --- a/qerror.c +++ b/qerror.c @@ -156,6 +156,10 @@ static const QErrorStringTable qerror_table[] = { .desc = "Invalid block format '%(name)'", }, { + .error_fmt = QERR_INVALID_OPTION_GROUP, + .desc = "There is no option group '%(group)'", + }, + { .error_fmt = QERR_INVALID_PARAMETER, .desc = "Invalid parameter '%(name)'", }, diff --git a/qerror.h b/qerror.h index 4cbba48..b4c8758 100644 --- a/qerror.h +++ b/qerror.h @@ -139,6 +139,9 @@ QError *qobject_to_qerror(const QObject *obj); #define QERR_INVALID_BLOCK_FORMAT \ "{ 'class': 'InvalidBlockFormat', 'data': { 'name': %s } }" +#define QERR_INVALID_OPTION_GROUP \ + "{ 'class': 'InvalidOptionGroup', 'data': { 'group': %s } }" + #define QERR_INVALID_PARAMETER \ "{ 'class': 'InvalidParameter', 'data': { 'name': %s } }"