diff src/core/sat_main.py @ 949:b4cd968e30fb

core: fixed bad closure in connection intialisation sequence (profileConnected in plugins were not called correctly)
author Goffi <goffi@goffi.org>
date Mon, 31 Mar 2014 12:23:13 +0200
parents e1842ebcb2f3
children 027a054c6dda
line wrap: on
line diff
--- a/src/core/sat_main.py	Mon Mar 31 12:23:10 2014 +0200
+++ b/src/core/sat_main.py	Mon Mar 31 12:23:13 2014 +0200
@@ -260,7 +260,7 @@
             d = current.getConnectionDeferred()
             d.addCallback(lambda dummy: current.roster.got_roster)  # we want to be sure that we got the roster
             for callback in plugin_conn_cb:
-                d.addCallback(lambda dummy: callback(profile))
+                d.addCallback(lambda dummy, callback=callback: callback(profile))
             return d
 
         self.memory.startProfileSession(profile)