[Libvirt-cim] [PATCH 3 of 8] This patch exposes error messages from libvirt calls in VirtualSystemManagementService

Richard Maciel rmaciel at linux.vnet.ibm.com
Fri Feb 27 21:10:19 UTC 2009


# HG changeset patch
# User Richard Maciel <rmaciel at linux.vnet.ibm.com>
# Date 1235768854 10800
# Node ID 26cbb2d7160307834cfa1fb5d77079532e534774
# Parent  b5acbf9fcbba3568fba1f7ce2d721a0886a177ab
This patch exposes error messages from libvirt calls in VirtualSystemManagementService

Signed-off-by: Richard Maciel <rmaciel at linux.vnet.ibm.com>

diff -r b5acbf9fcbba -r 26cbb2d71603 src/Virt_EnabledLogicalElementCapabilities.c
--- a/src/Virt_EnabledLogicalElementCapabilities.c	Fri Feb 27 18:07:21 2009 -0300
+++ b/src/Virt_EnabledLogicalElementCapabilities.c	Fri Feb 27 18:07:34 2009 -0300
@@ -123,9 +123,10 @@
         for (i = 0; i < count; i++) {
                 name = virDomainGetName(list[i]);
                 if (name == NULL) {
-                        cu_statusf(_BROKER, &s,
-                                   CMPI_RC_ERR_FAILED,
-                                   "Unable to get domain names");
+                        virt_set_status(_BROKER, &s,
+                                        CMPI_RC_ERR_FAILED,
+                                        conn,
+                                        "Unable to get domain names");
                         goto end;
                 }
 
@@ -169,10 +170,11 @@
         
         dom = virDomainLookupByName(conn, name);
         if (dom == NULL) {
-                cu_statusf(broker, &s,
-                           CMPI_RC_ERR_NOT_FOUND,
-                           "No such instance (%s)",
-                           name);
+                virt_set_status(broker, &s,
+                                CMPI_RC_ERR_NOT_FOUND,
+                                conn,
+                                "No such instance (%s)",
+                                name);
                 goto out;
         }
 




More information about the Libvirt-cim mailing list