Author: andar
Revision: 6018
Log:
Disconnect from daemon if getting the info fails
Diff:
Modified: branches/1.2_RC/deluge/ui/gtkui/connectionmanager.py
===================================================================
--- branches/1.2_RC/deluge/ui/gtkui/connectionmanager.py 2009-12-13
21:29:46 UTC (rev 6017)
+++ branches/1.2_RC/deluge/ui/gtkui/connectionmanager.py 2009-12-13
21:34:26 UTC (rev 6018)
@@ -271,16 +271,17 @@
self.__update_buttons()
c.disconnect()
- def on_info_fail(reason):
+ def on_info_fail(reason, c):
if not self.running:
return
if row:
row[HOSTLIST_COL_STATUS] = _("Offline")
self.__update_buttons()
+ c.disconnect()
d = c.daemon.info()
d.addCallback(on_info, c)
- d.addErrback(on_info_fail)
+ d.addErrback(on_info_fail, c)
def on_connect_failed(reason, host_info):
if not self.running:
Modified: trunk/deluge/ui/gtkui/connectionmanager.py
===================================================================
--- trunk/deluge/ui/gtkui/connectionmanager.py 2009-12-13 21:29:46 UTC (rev
6017)
+++ trunk/deluge/ui/gtkui/connectionmanager.py 2009-12-13 21:34:26 UTC (rev
6018)
@@ -271,16 +271,17 @@
self.__update_buttons()
c.disconnect()
- def on_info_fail(reason):
+ def on_info_fail(reason, c):
if not self.running:
return
if row:
row[HOSTLIST_COL_STATUS] = _("Offline")
self.__update_buttons()
+ c.disconnect()
d = c.daemon.info()
d.addCallback(on_info, c)
- d.addErrback(on_info_fail)
+ d.addErrback(on_info_fail, c)
def on_connect_failed(reason, host_info):
if not self.running:
--
You received this message because you are subscribed to the Google Groups
"deluge-commit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/deluge-commit?hl=en.