From 5e5733e40a1589faf6cd4c45482521a06e09db11 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Tue, 17 Jun 2008 05:39:20 +0000 Subject: [PATCH] fix traceback when no control is opened. fixes #4024, #4028 --- src/gajim.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gajim.py b/src/gajim.py index 00923376f..f90419a69 100755 --- a/src/gajim.py +++ b/src/gajim.py @@ -2749,7 +2749,9 @@ class Interface: win = self.msg_win_mgr.get_window(fjid, account) if win: - ctrl = win.get_controls(fjid, account)[0] + ctrls = win.get_controls(fjid, account) + if ctrls: + ctrl = ctrls[0] if not ctrl: ctrl = self.new_chat(contact, account,