From ed95cedc365a010346f50a681656ccc2b15af079 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Sat, 16 Feb 2013 20:00:07 +0100 Subject: [PATCH] fix get_visible_range() can return None --- src/disco.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/disco.py b/src/disco.py index 6dcddecc5..326823cf6 100644 --- a/src/disco.py +++ b/src/disco.py @@ -1905,8 +1905,10 @@ class MucBrowser(AgentBrowser): # Prevent a silly warning, try again in a bit. self._fetch_source = GObject.timeout_add(100, self._start_info_query) return - # We have to do this in a pygtk <2.8 compatible way :/ - start, end = view.get_visible_range() + range_ = view.get_visible_range() + if not range_: + return + start, end = range_ iter_ = self.model.get_iter(start) while iter_: if not self.model.get_value(iter_, 6):