summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-04-13 12:32:28 +0200
committerhut <hut@lavabit.com>2010-04-13 12:32:46 +0200
commit62e5fdf30596c76e4b9551964e5af8ea21c9741c (patch)
tree83eac1cbb51d7ed13254c5874d04d1f541bbc299
parent30785f2bdbfbaed60037d598561e7fed60c64256 (diff)
downloadranger-62e5fdf30596c76e4b9551964e5af8ea21c9741c.tar.gz
gui.bar: Fixed Zero Division Error
-rw-r--r--ranger/gui/bar.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ranger/gui/bar.py b/ranger/gui/bar.py
index 8b8eb33c..f5e34eb1 100644
--- a/ranger/gui/bar.py
+++ b/ranger/gui/bar.py
@@ -68,7 +68,8 @@ class Bar(object):
 		rightsize = self.right.sumsize()
 		nonfixed_items = self.left.nonfixed_items()
 
-		itemsize = int(float(wid - rightsize - fixedsize) / nonfixed_items) + 1
+		itemsize = int(float(wid - rightsize - fixedsize) / \
+				(nonfixed_items + 1)) + 1
 
 		for item in self.left:
 			if not item.fixed: