esx: Don't treat an empty root snapshot list as error

An empty root snapshot list was considered as error condition. Creating a
new snapshot would fail if the domain didn't have snapshots yet, because
the snapshot-create function tries to lookup the list of existing snapshots
in order to verify that the snapshot name is unique. This fails if the
domain doesn't have snapshots yet.

Removing the NULL check from esxVI_LookupRootSnapshotTreeList fixes this.
This commit is contained in:
Chris Wong 2010-04-21 11:47:15 +02:00 committed by Matthias Bolte
parent 3f52921d43
commit b1fab0c21c

View File

@ -2503,12 +2503,6 @@ esxVI_LookupRootSnapshotTreeList
}
}
if (*rootSnapshotTreeList == NULL) {
ESX_VI_ERROR(VIR_ERR_INTERNAL_ERROR, "%s",
_("Could not lookup root snapshot list"));
goto failure;
}
cleanup:
esxVI_String_Free(&propertyNameList);
esxVI_ObjectContent_Free(&virtualMachine);