From 803f88b1c112b6f52e23376113b9528773d3bdf5 Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Wed, 31 Mar 2010 13:24:55 -0300 Subject: [PATCH 40/66] error: New QERR_PROPERTY_VALUE_IN_USE RH-Author: Markus Armbruster Message-id: <1270041921-28969-41-git-send-email-armbru@redhat.com> Patchwork-id: 8246 O-Subject: [PATCH 40/66] error: New QERR_PROPERTY_VALUE_IN_USE Bugzilla: 579470 RH-Acked-by: Kevin Wolf RH-Acked-by: Juan Quintela RH-Acked-by: Luiz Capitulino (cherry picked from commit 9c5eff958d527d1803114a6f78d086fb313b9bd2) --- qerror.c | 4 ++++ qerror.h | 3 +++ 2 files changed, 7 insertions(+), 0 deletions(-) Signed-off-by: Eduardo Habkost --- qerror.c | 4 ++++ qerror.h | 3 +++ 2 files changed, 7 insertions(+), 0 deletions(-) diff --git a/qerror.c b/qerror.c index 78598c0..7420e95 100644 --- a/qerror.c +++ b/qerror.c @@ -117,6 +117,10 @@ static const QErrorStringTable qerror_table[] = { .desc = "Property '%(device).%(property)' doesn't take value '%(value)'", }, { + .error_fmt = QERR_PROPERTY_VALUE_IN_USE, + .desc = "Property '%(device).%(property)' can't take value '%(value)', it's in use", + }, + { .error_fmt = QERR_QMP_BAD_INPUT_OBJECT, .desc = "Bad QMP input object", }, diff --git a/qerror.h b/qerror.h index 3ee46fa..810b851 100644 --- a/qerror.h +++ b/qerror.h @@ -99,6 +99,9 @@ QError *qobject_to_qerror(const QObject *obj); #define QERR_PROPERTY_VALUE_BAD \ "{ 'class': 'PropertyValueBad', 'data': { 'device': %s, 'property': %s, 'value': %s } }" +#define QERR_PROPERTY_VALUE_IN_USE \ + "{ 'class': 'PropertyValueInUse', 'data': { 'device': %s, 'property': %s, 'value': %s } }" + #define QERR_QMP_BAD_INPUT_OBJECT \ "{ 'class': 'QMPBadInputObject', 'data': { 'expected': %s } }" -- 1.7.0.3