# HG changeset patch
# User Heidi Eckhart <heidieck(a)linux.vnet.ibm.com>
# Date 1196242630 -3600
# Node ID ebb86619d5ca80ad7815f9d70d2c8a87698a5f0f
# Parent d86ff33c049964d91fe8b800e5562f178b3cf4a0
Housekeeping of label error to ECTP
Removed labels error and let label out do all the free() stuff
Signed-off-by: Heidi Eckhart <heidieck(a)linux.vnet.ibm.com>
diff -r d86ff33c0499 -r ebb86619d5ca src/Virt_ElementConformsToProfile.c
--- a/src/Virt_ElementConformsToProfile.c Wed Nov 28 10:33:33 2007 +0100
+++ b/src/Virt_ElementConformsToProfile.c Wed Nov 28 10:37:10 2007 +0100
@@ -70,14 +70,14 @@ static CMPIStatus elem_instances(const C
op = CMNewObjectPath(_BROKER, CIM_VIRT_NS, classname, &s);
if ((s.rc != CMPI_RC_OK) || CMIsNullObject(op))
- goto error;
+ goto out;
en = CBEnumInstances(_BROKER, info->context , op, NULL, &s);
if (en == NULL) {
CMSetStatusWithChars(_BROKER, &s,
CMPI_RC_ERR_FAILED,
"Upcall enumInstances to target class
failed.");
- goto error;
+ goto out;
}
while (CMHasNext(en, &s)) {
@@ -86,15 +86,15 @@ static CMPIStatus elem_instances(const C
CMSetStatusWithChars(_BROKER, &s,
CMPI_RC_ERR_FAILED,
"Failed to retrieve enumeration
entry.");
- goto error;
+ goto out;
}
inst_list_add(list, data.value.inst);
}
- error:
+ out:
free(classname);
- out:
+
return s;
}
@@ -124,14 +124,13 @@ static CMPIStatus prof_to_elem(const CMP
s = elem_instances(ref, info, list,
profiles[i], conn);
if ((s.rc != CMPI_RC_OK))
- goto error;
+ goto out;
break;
}
}
- error:
+ out:
free(id);
- out:
virConnectClose(conn);
return s;
@@ -173,15 +172,14 @@ static CMPIStatus elem_to_prof(const CMP
CMSetStatusWithChars(_BROKER, &s,
CMPI_RC_ERR_FAILED,
"Can't create profile
instance.");
- goto error;
+ goto out;
}
inst_list_add(list, instance);
}
-
- error:
+
+ out:
free(classname);
- out:
virConnectClose(conn);
return s;