]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: storage: Fix virStorageSourceGetActualType if volume was not translated
authorPeter Krempa <pkrempa@redhat.com>
Tue, 25 Jun 2019 10:59:07 +0000 (12:59 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Wed, 26 Jun 2019 10:28:31 +0000 (12:28 +0200)
commit6dd609114dafa5267e25fc34369f49420db917a1
treed665b836d486493b49ce931ea16a1ab9bab8d168
parent1e49d1ec79e624284b1001779c71c2e903afd28f
util: storage: Fix virStorageSourceGetActualType if volume was not translated

virStorageSourceGetActualType would return VIR_STORAGE_TYPE_NONE in case
when a virStorageSource of (top level) type VIR_STORAGE_TYPE_VOLUME was
not prepared to use by the vm by calling
virDomainDiskTranslateSourcePool.

Fix this issue by returning VIR_STORAGE_TYPE_VOLUME in case when the
volume was not translated yet.

Additionally also add documentation for the function describing the
quirk.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/util/virstoragefile.c