]> xenbits.xensource.com Git - libvirt.git/commit
Allow cloning volumes with no capacity specified
authorJán Tomko <jtomko@redhat.com>
Tue, 17 Feb 2015 15:54:53 +0000 (16:54 +0100)
committerJán Tomko <jtomko@redhat.com>
Mon, 2 Mar 2015 07:07:11 +0000 (08:07 +0100)
commite3f1d2a8201e552837f77ce38613a555524888cc
treeaa6347a69359cc54d6395b71dfe5b390040fe7bb
parent2bd47d9c64b4d3d9606161453b9a821d0192174e
Allow cloning volumes with no capacity specified

In virStorageVolCreateXML, add VIR_VOL_XML_PARSE_NO_CAPACITY
to the call parsing the XML of the new volume to make the capacity
optional.

If the capacity is omitted, use the capacity of the old volume.
We already do that for values that are less than the original
volume capacity.
src/storage/storage_driver.c
tests/storagevolxml2argvdata/qcow2-nocapacity-convert-prealloc.argv [new file with mode: 0644]
tests/storagevolxml2argvtest.c
tests/storagevolxml2xmlin/vol-qcow2-nocapacity.xml [new file with mode: 0644]
tests/storagevolxml2xmlout/vol-qcow2-nocapacity.xml [new file with mode: 0644]
tests/storagevolxml2xmltest.c