# HG changeset patch
# User Heidi Eckhart <heidieck(a)linux.vnet.ibm.com>
# Date 1201258972 -3600
# Node ID 1d49df7cf101bfb535dac3b96674ca7ba7ec1244
# Parent a6f0628644c1a666eea8be9993ad84ca688d65f4
HostSystem: Use cmpiutil function to validate incoming reference
Signed-off-by: Heidi Eckhart <heidieck(a)linux.vnet.ibm.com>
diff -r a6f0628644c1 -r 1d49df7cf101 src/Virt_HostSystem.c
--- a/src/Virt_HostSystem.c Fri Jan 25 11:53:35 2008 +0100
+++ b/src/Virt_HostSystem.c Fri Jan 25 12:02:52 2008 +0100
@@ -41,16 +41,10 @@ CMPIStatus validate_host_ref(const CMPIB
{
CMPIStatus s = {CMPI_RC_OK, NULL};
CMPIInstance *inst;
- const char *prop;
s = get_host_cs(broker, ref, &inst);
-
- prop = cu_compare_ref(ref, inst);
- if (prop != NULL) {
- cu_statusf(broker, &s,
- CMPI_RC_ERR_NOT_FOUND,
- "No such instance (%s)", prop);
- }
+ if (inst != NULL)
+ s = cu_validate_ref(broker, ref, inst);
return s;
}