Philipp Hörist pushed to branch gajim_1.3 at gajim / gajim
Commits:
e98cf336 by ValdikSS at 2021-12-15T03:13:02+03:00
Backport jingle-initiator, fixes jingle file transfer from Conversations
Conversations XMPP client does not include initiator attribute in Jingle
connection stanza, while Gajim 1.3 expects it and fails to accept the
file or even show the file transfer dialog without it.
- - - - -
1 changed file:
- gajim/common/jingle_session.py
Changes:
=====================================
gajim/common/jingle_session.py
=====================================
@@ -516,7 +516,17 @@ def __on_session_initiate(self, stanza, jingle, error,
action):
"""
if self.state != JingleStates.ENDED:
raise OutOfOrder
- self.initiator = jingle['initiator']
+
+ # In "session-initiate", the <jingle/> element SHOULD possess an
+ # 'initiator' attribute. If it differs from the JID 'from', jingle
+ # 'initiator' SHOULD be ignored.
+ if jingle['initiator'] is None:
+ self.initiator = str(stanza['from'])
+ elif str(jingle['initiator']) != str(stanza['from']):
+ self.initiator = str(stanza['from'])
+ else:
+ self.initiator = str(jingle['initiator'])
+
self.responder = self.ourjid
self.peerjid = self.initiator
self.accepted = False # user did not accept this session yet
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/e98cf3367c962c8de4345e27ff09e68f6e3a39c8
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/e98cf3367c962c8de4345e27ff09e68f6e3a39c8
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list
[email protected]
https://lists.gajim.org/cgi-bin/listinfo/commits