[transmageddon] further attempt at fixing division by zero issue
- From: Christian Fredrik Kalager Schaller <uraeus src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [transmageddon] further attempt at fixing division by zero issue
- Date: Thu, 17 Sep 2009 15:13:58 +0000 (UTC)
commit 4fc589070509bf71b701b1e3cda4167d409104f8
Author: Christian Schaller <christian schaller collabora co uk>
Date: Thu Sep 17 16:15:17 2009 +0100
further attempt at fixing division by zero issue
src/transmageddon.py | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/src/transmageddon.py b/src/transmageddon.py
index 3cdd2a1..c5b8040 100644
--- a/src/transmageddon.py
+++ b/src/transmageddon.py
@@ -343,6 +343,8 @@ class TransmageddonUI (gtk.glade.XML):
# print percent_remain
if percent != 0:
rem = (timespent / percent) * percent_remain
+ else:
+ rem = 0.1
min = rem / 60
sec = rem % 60
time_rem = _("%(min)d:%(sec)02d") % {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]