On 04/04/14 06:32, Eric Blake wrote: > Right now, virStorageFileMetadata tracks bool backingStoreIsFile > for whether the backing string specified in metadata can be > resolved as a file (covering both block and regular file > resources) or is treated as a network protocol. But when > merging this struct with virStorageSource, it will be easier > to just actually track which type of resource it is, as well > as have a reserved value for the case where the resource type > is unknown (or had an error during probing). > > * src/util/virstoragefile.h (virStorageType): Add a placeholder > value, swap order to match similar public enum. > * src/util/virstoragefile.c (virStorage): Update string mapping. > * src/conf/domain_conf.c (virDomainDiskSourceParse) > (virDomainDiskDefParseXML, virDomainDiskDefFormat) > (virDomainDiskSourceFormat): Adjust clients. > * src/conf/snapshot_conf.c (virDomainSnapshotDiskDefParseXML): > Likewise. > * src/qemu/qemu_driver.c > (qemuDomainSnapshotPrepareDiskExternalBackingInactive) > (qemuDomainSnapshotPrepareDiskExternalOverlayActive) > (qemuDomainSnapshotPrepareDiskExternalOverlayInactive) > (qemuDomainSnapshotPrepareDiskInternal) > (qemuDomainSnapshotCreateSingleDiskActive): Likewise. > * src/qemu/qemu_command.c (qemuGetDriveSourceString): Likewise. > > Signed-off-by: Eric Blake <eblake@xxxxxxxxxx> > --- > src/conf/domain_conf.c | 10 ++++++---- > src/conf/snapshot_conf.c | 2 +- > src/qemu/qemu_command.c | 1 + > src/qemu/qemu_driver.c | 11 +++++++++-- > src/util/virstoragefile.c | 3 ++- > src/util/virstoragefile.h | 8 ++++++-- > 6 files changed, 25 insertions(+), 10 deletions(-) ACK, having _TYPE_BLOCK as index 0 caused grief a lot of times for me. Peter
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list