virt-manager/virtinst-clone-disks.patch
Charles Arnold ae026a575b - Update to virt-manager 0.10.0
* Merged code with python-virtinst. virtinst is no longer public
  * Port from GTK2 to GTK3 (Daniel Berrange, Cole Robinson)
  * Port from gconf to gsettings
  * Port from autotools to python distutils
  * Remove virt-manager-tui
  * Remove HAL support
  * IPv6 and static route virtual network support (Gene Czarcinski)
  * virt-install: Add –cpu host-passthrough (Ken ICHIKAWA, Hu Tao)

OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=129
2013-11-26 21:23:05 +00:00

37 lines
1.6 KiB
Diff

Index: virt-manager-0.10.0/virtinst/CloneManager.py
===================================================================
--- virt-manager-0.10.0.orig/virtinst/CloneManager.py
+++ virt-manager-0.10.0/virtinst/CloneManager.py
@@ -530,6 +530,7 @@ class CloneDesign(object):
xmldisk.type = clone_disk.type
xmldisk.path = clone_disk.path
xmldisk.driver_type = orig_disk.driver_type
+ xmldisk.driver_name = orig_disk.driver_name
# Save altered clone xml
self._clone_xml = self._guest.get_xml_config()
Index: virt-manager-0.10.0/virtinst/VirtualDisk.py
===================================================================
--- virt-manager-0.10.0.orig/virtinst/VirtualDisk.py
+++ virt-manager-0.10.0/virtinst/VirtualDisk.py
@@ -1203,6 +1203,10 @@ class VirtualDisk(VirtualDevice):
if util.is_vdisk(self.path):
drvname = self.DRIVER_TAP
drvtype = self.DRIVER_TAP_VDISK
+ elif drvname is None and drvtype:
+ drvtypes = ['qcow2', 'vmdk']
+ if drvtype in drvtypes:
+ drvname = 'tap'
return drvname or None, drvtype or None
@@ -1543,6 +1547,8 @@ class VirtualDisk(VirtualDevice):
if drvxml and self.driver_name is None:
if self.is_qemu():
self.driver_name = "qemu"
+ else:
+ self.driver_name = self.get_driver_name()
if not self.driver_name is None:
drvxml = (" name='%s'" % self.driver_name) + drvxml