[Pkg-libvirt-commits] [SCM] Virtinst Debian packaging branch, master, updated. debian/0.600.3-2

Guido Günther agx at sigxcpu.org
Thu Oct 11 17:15:51 UTC 2012


The following commit has been merged in the master branch:
commit 04e309a8a2dc9c2a271a80c8685125288fb1ef3e
Author: Guido Günther <agx at sigxcpu.org>
Date:   Thu Oct 11 19:03:35 2012 +0200

    Don't fail if no meter is used

diff --git a/debian/patches/0007-Don-t-fail-if-no-meter-is-used.patch b/debian/patches/0007-Don-t-fail-if-no-meter-is-used.patch
new file mode 100644
index 0000000..30a05c1
--- /dev/null
+++ b/debian/patches/0007-Don-t-fail-if-no-meter-is-used.patch
@@ -0,0 +1,41 @@
+From: =?UTF-8?q?Guido=20G=C3=BCnther?= <agx at sigxcpu.org>
+Date: Thu, 11 Oct 2012 18:29:17 +0200
+Subject: Don't fail if no meter is used
+
+like in the other modules
+---
+ virtinst/DistroInstaller.py |   11 +++++++----
+ 1 file changed, 7 insertions(+), 4 deletions(-)
+
+diff --git a/virtinst/DistroInstaller.py b/virtinst/DistroInstaller.py
+index 3a3b5a7..f5e03a0 100644
+--- a/virtinst/DistroInstaller.py
++++ b/virtinst/DistroInstaller.py
+@@ -125,8 +125,9 @@ def _upload_file(conn, meter, destpool, src):
+ 
+         # Start transfer
+         total = 0
+-        meter.start(size=size,
+-                    text=_("Transferring %s") % os.path.basename(src))
++        if meter:
++            meter.start(size=size,
++                        text=_("Transferring %s") % os.path.basename(src))
+         while True:
+             #blocksize = (1024 ** 2)
+             blocksize = 1024
+@@ -136,11 +137,13 @@ def _upload_file(conn, meter, destpool, src):
+ 
+             safe_send(data)
+             total += len(data)
+-            meter.update(total)
++            if meter:
++                meter.update(total)
+ 
+         # Cleanup
+         stream.finish()
+-        meter.end(size)
++        if meter:
++            meter.end(size)
+     except:
+         if vol:
+             vol.delete(0)
diff --git a/debian/patches/series b/debian/patches/series
index ad31b7b..02232f5 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -4,3 +4,4 @@
 0004-LogicalPool-properly-pass-on-autostart-flag.patch
 0005-Don-t-overwrite-target-element-for-disks-that-have-i.patch
 0006-virt-install-avoid-disk-name-collisions.patch
+0007-Don-t-fail-if-no-meter-is-used.patch

-- 
Virtinst Debian packaging



More information about the Pkg-libvirt-commits mailing list