]> git.ipfire.org Git - thirdparty/libvirt.git/commit
storageVolWipePattern: Don't take shortcut to refreshPool()
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 28 Feb 2019 16:35:14 +0000 (17:35 +0100)
committerMichal Privoznik <mprivozn@redhat.com>
Mon, 18 Mar 2019 12:20:36 +0000 (13:20 +0100)
commit2e556e00ca269d888e4cc2632e1de69c979ea251
treebdf07e77920aa0d1ee2f6dd1a5889c701989cb1c
parentf7b9d6f78bff158a929eb248b31c77f852c1c6f8
storageVolWipePattern: Don't take shortcut to refreshPool()

In d16f803d780 we've tried to solve an issue that after wiping an
image its format might have changed (e.g. from qcow2 to raw) but
libvirt wasn't probing the image format. We fixed this by calling
virStorageBackendRefreshVolTargetUpdate() which is what
refreshPool() would end up calling. But this shortcut is not good
enough because the function is called only for local types of
volumes (like dir, fs, netfs). But now that more backends support
volume wiping we have to call the function with more caution.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
src/storage/storage_driver.c