Patchwork [14/22] QError: New QERR_DEVICE_NO_SNAPSHOT

login
register
mail settings
Submitter Luiz Capitulino
Date April 20, 2010, 9:09 p.m.
Message ID <1271797792-24571-15-git-send-email-lcapitulino@redhat.com>
Download mbox | patch
Permalink /patch/50590/
State New
Headers show

Comments

Luiz Capitulino - April 20, 2010, 9:09 p.m.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 qerror.c |    4 ++++
 qerror.h |    3 +++
 2 files changed, 7 insertions(+), 0 deletions(-)

Patch

diff --git a/qerror.c b/qerror.c
index b0cd7b1..078fc43 100644
--- a/qerror.c
+++ b/qerror.c
@@ -101,6 +101,10 @@  static const QErrorStringTable qerror_table[] = {
         .desc      = "Device '%(device)' has no child bus",
     },
     {
+        .error_fmt = QERR_DEVICE_NO_SNAPSHOT,
+        .desc      = "Device '%(device)' doesn't support snapshots",
+    },
+    {
         .error_fmt = QERR_DUPLICATE_ID,
         .desc      = "Duplicate ID '%(id)' for %(object)",
     },
diff --git a/qerror.h b/qerror.h
index 900a62b..da12160 100644
--- a/qerror.h
+++ b/qerror.h
@@ -91,6 +91,9 @@  QError *qobject_to_qerror(const QObject *obj);
 #define QERR_DEVICE_NO_BUS \
     "{ 'class': 'DeviceNoBus', 'data': { 'device': %s } }"
 
+#define QERR_DEVICE_NO_SNAPSHOT \
+    "{ 'class': 'DeviceNoSnapshot', 'data': { 'device': %s } }"
+
 #define QERR_DUPLICATE_ID \
     "{ 'class': 'DuplicateId', 'data': { 'id': %s, 'object': %s } }"