pidgin: a87af641: yahoo: fix decoding of P2P session_id
rekkanoryo at pidgin.im
rekkanoryo at pidgin.im
Sat Mar 13 16:25:52 EST 2010
-----------------------------------------------------------------
Revision: a87af6413b6aef7fd11608c15fb50aee2ac3d21e
Ancestor: 17c1e048674ec57bdadbafc0b1e598a37143eccd
Author: vamposdecampos at gmail.com
Date: 2010-03-13T21:20:54
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/a87af6413b6aef7fd11608c15fb50aee2ac3d21e
Modified files:
libpurple/protocols/yahoo/libymsg.c
libpurple/protocols/yahoo/libymsg.h
ChangeLog:
yahoo: fix decoding of P2P session_id
Apparently, inbound P2P packets containing key-11 session_id are
no longer sent by the server with a YAHOO_STATUS_BRB, but rather
a status value of 11.
Since we don't pick up the session_id, the first text message we
send over the P2P connection will have a key-11 value of 0, and cause
the remote (yahoo) client to disconnect us. This is causing the
"lost second line in a conversation" syndrome.
Fix it by also accepting status 11 in yahoo_process_p2p().
Fixes #10733.
-------------- next part --------------
============================================================
--- libpurple/protocols/yahoo/libymsg.c c72e755bfc3f8f6f9280f2e79ece8f0e9b18e439
+++ libpurple/protocols/yahoo/libymsg.c 1b69a57ae7d594303a9e9c9d4f40a5e21eed7fa8
@@ -2733,8 +2733,9 @@ static void yahoo_process_p2p(PurpleConn
PurpleAccount *account;
YahooFriend *f;
- /* if status is not 1 ie YAHOO_STATUS_BRB, the packet bounced back, so contains our own ip */
- if(!(pkt->status == YAHOO_STATUS_BRB))
+ /* if status is not YAHOO_STATUS_BRB or YAHOO_STATUS_P2P, the packet bounced back,
+ * so it contains our own ip */
+ if(pkt->status != YAHOO_STATUS_BRB && pkt->status != YAHOO_STATUS_P2P)
return ;
while (l) {
============================================================
--- libpurple/protocols/yahoo/libymsg.h 8e984834fb1d7ff646200227a9b586b97f4cea0e
+++ libpurple/protocols/yahoo/libymsg.h 69498cd508e3de349dbd49eebcba06a0679fd589
@@ -119,6 +119,7 @@ enum yahoo_status {
YAHOO_STATUS_ONVACATION,
YAHOO_STATUS_OUTTOLUNCH,
YAHOO_STATUS_STEPPEDOUT,
+ YAHOO_STATUS_P2P = 11,
YAHOO_STATUS_INVISIBLE = 12,
YAHOO_STATUS_CUSTOM = 99,
YAHOO_STATUS_IDLE = 999,
More information about the Commits
mailing list