* so that the open could be re-tried as that user:group.
*/
if (!virStorageSourceHasBacking(disk->src))
- virStorageFileGetMetadata(disk->src, -1, -1, false, false);
+ virStorageFileGetMetadata(disk->src, -1, -1, false);
/* XXX passing ignoreOpenFailure = true to get back to the behavior
* from before using virDomainDiskDefForeachPath. actually we should
virStorageFileGetMetadataRecurse(virStorageSourcePtr src,
virStorageSourcePtr parent,
uid_t uid, gid_t gid,
- bool allow_probe,
bool report_broken,
virHashTablePtr cycle,
unsigned int depth)
int backingFormat;
int rv;
- VIR_DEBUG("path=%s format=%d uid=%u gid=%u probe=%d",
+ VIR_DEBUG("path=%s format=%d uid=%u gid=%u",
src->path, src->format,
- (unsigned int)uid, (unsigned int)gid, allow_probe);
+ (unsigned int)uid, (unsigned int)gid);
/* exit if we can't load information about the current image */
rv = virStorageFileSupportsBackingChainTraversal(src);
if (!(backingStore = virStorageSourceNewFromBacking(src)))
goto cleanup;
- if (backingFormat == VIR_STORAGE_FILE_AUTO && !allow_probe)
+ if (backingFormat == VIR_STORAGE_FILE_AUTO)
backingStore->format = VIR_STORAGE_FILE_RAW;
else if (backingFormat == VIR_STORAGE_FILE_AUTO_SAFE)
backingStore->format = VIR_STORAGE_FILE_AUTO;
if ((ret = virStorageFileGetMetadataRecurse(backingStore, parent,
uid, gid,
- allow_probe, report_broken,
+ report_broken,
cycle, depth + 1)) < 0) {
if (report_broken)
goto cleanup;
int
virStorageFileGetMetadata(virStorageSourcePtr src,
uid_t uid, gid_t gid,
- bool allow_probe,
bool report_broken)
{
- VIR_DEBUG("path=%s format=%d uid=%u gid=%u probe=%d, report_broken=%d",
+ VIR_DEBUG("path=%s format=%d uid=%u gid=%u report_broken=%d",
src->path, src->format, (unsigned int)uid, (unsigned int)gid,
- allow_probe, report_broken);
+ report_broken);
virHashTablePtr cycle = NULL;
virStorageType actualType = virStorageSourceGetActualType(src);
if (src->format <= VIR_STORAGE_FILE_NONE) {
if (actualType == VIR_STORAGE_TYPE_DIR)
src->format = VIR_STORAGE_FILE_DIR;
- else if (allow_probe)
- src->format = VIR_STORAGE_FILE_AUTO;
else
src->format = VIR_STORAGE_FILE_RAW;
}
ret = virStorageFileGetMetadataRecurse(src, src, uid, gid,
- allow_probe, report_broken, cycle, 1);
+ report_broken, cycle, 1);
virHashFree(cycle);
return ret;