esxParseVMXFileName(const char *fileName,
void *opaque,
char **out,
- bool allow_missing G_GNUC_UNUSED)
+ bool allow_missing)
{
esxVMX_Data *data = opaque;
esxVI_String *propertyNameList = NULL;
}
if (!datastoreList) {
- virReportError(VIR_ERR_INTERNAL_ERROR,
- _("File name '%s' refers to non-existing datastore '%s'"),
- fileName, datastoreName);
+ if (allow_missing) {
+ ret = 0;
+ } else {
+ virReportError(VIR_ERR_INTERNAL_ERROR,
+ _("File name '%s' refers to non-existing datastore '%s'"),
+ fileName, datastoreName);
+ }
goto cleanup;
}