From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NfOD7-0007a2-Sg for qemu-devel@nongnu.org; Wed, 10 Feb 2010 20:51:17 -0500 Received: from [199.232.76.173] (port=57768 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NfOD7-0007ZS-CF for qemu-devel@nongnu.org; Wed, 10 Feb 2010 20:51:17 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NfOD6-0001Lu-89 for qemu-devel@nongnu.org; Wed, 10 Feb 2010 20:51:17 -0500 Received: from mx1.redhat.com ([209.132.183.28]:13514) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NfOD5-0001Lq-SV for qemu-devel@nongnu.org; Wed, 10 Feb 2010 20:51:16 -0500 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o1B1pFGY009102 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 10 Feb 2010 20:51:15 -0500 From: Luiz Capitulino Date: Wed, 10 Feb 2010 23:50:07 -0200 Message-Id: <1265853007-27300-22-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1265853007-27300-1-git-send-email-lcapitulino@redhat.com> References: <1265853007-27300-1-git-send-email-lcapitulino@redhat.com> Subject: [Qemu-devel] [PATCH 21/21] Monitor: Report more than one error in handlers List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: armbru@redhat.com Handlers can generate only one error in a call, we let the programmer know if they brake this rule and clients will only get the first generated error. Signed-off-by: Luiz Capitulino --- monitor.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/monitor.c b/monitor.c index d9592e9..6a64e6e 100644 --- a/monitor.c +++ b/monitor.c @@ -4760,7 +4760,8 @@ void qemu_error_internal(const char *file, int linenr, const char *func, if (!qemu_error_sink->mon->error) { qemu_error_sink->mon->error = qerror; } else { - /* XXX: warn the programmer */ + MON_DEBUG("Additional error report at %s:%d\n", qerror->file, + qerror->linenr); QDECREF(qerror); } break; -- 1.6.6