Philipp Hörist pushed to branch master at gajim / python-nbxmpp
Commits: 7f39ed31 by Philipp Hörist at 2018-12-14T20:14:48Z Fix bind after failed resume
We already received the features at the time of a failed resume so the handler is never called
- - - - -
1 changed file:
- nbxmpp/bind.py
Changes:
===================================== nbxmpp/bind.py ===================================== @@ -47,6 +47,12 @@ class NonBlockingBind(PlugIn): self._owner.RegisterHandler( 'features', self._on_features, xmlns=NS_STREAMS)
+ feats = self._owner.Dispatcher.Stream.features + if feats is not None: + if feats.getTag('bind', namespace=NS_BIND) is not None: + # We already received the features + self._on_features(None, feats) + def _on_features(self, _con, feats): """ Determine if server supports resource binding and set some internal @@ -123,4 +129,4 @@ class NonBlockingBind(PlugIn): if feats.getTag('sm', namespace=NS_STREAM_MGMT): self._owner.Smacks.send_enable() self._owner.Dispatcher.Event(Realm.CONNECTING, Event.CONNECTION_ACTIVE) - self.PlugOut() \ No newline at end of file + self.PlugOut()
View it on GitLab: https://dev.gajim.org/gajim/python-nbxmpp/commit/7f39ed31591c7d0eea66259d4b3...