# HG changeset patch
# User Richard Maciel <rmaciel(a)linux.vnet.ibm.com>
# Date 1235768879 10800
# Node ID f88cd8378600ba6a44183cf3f39a9a76c14b930c
# Parent 2c0bcc9729ec08d18516a8febd1c636bcb0b0dd1
This patch exposes additional error messages from libvirt calls in
Virt_VirtualSystemManagementService
* All get_dominfo() calls are considered as targets for error message exposition, since
they internally call virDomainGetXMLDesc
Signed-off-by: Richard Maciel <rmaciel(a)linux.vnet.ibm.com>
diff -r 2c0bcc9729ec -r f88cd8378600 src/Virt_VirtualSystemManagementService.c
--- a/src/Virt_VirtualSystemManagementService.c Fri Feb 27 18:07:52 2009 -0300
+++ b/src/Virt_VirtualSystemManagementService.c Fri Feb 27 18:07:59 2009 -0300
@@ -1075,9 +1075,10 @@
ret = get_dominfo(dom, domain);
if (ret == 0) {
- cu_statusf(_BROKER, &s,
- CMPI_RC_ERR_FAILED,
- "Error getting referenced configuration");
+ virt_set_status(_BROKER, &s,
+ CMPI_RC_ERR_FAILED,
+ conn,
+ "Error getting referenced configuration");
goto out;
}
@@ -1334,10 +1335,11 @@
}
if (!get_dominfo(dom, &dominfo)) {
- cu_statusf(_BROKER, &s,
- CMPI_RC_ERR_FAILED,
- "Unable to find existing domain `%s' to
modify",
- name);
+ virt_set_status(_BROKER, &s,
+ CMPI_RC_ERR_FAILED,
+ conn,
+ "Unable to find existing domain `%s' to
modify",
+ name);
goto out;
}
@@ -1721,9 +1723,10 @@
CMPIObjectPath *op;
if (!get_dominfo(dom, &dominfo)) {
- cu_statusf(_BROKER, &s,
- CMPI_RC_ERR_FAILED,
- "Internal error (getting domain info)");
+ virt_set_status(_BROKER, &s,
+ CMPI_RC_ERR_FAILED,
+ virDomainGetConnect(dom),
+ "Internal error (getting domain info)");
goto out;
}