diff options
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/MSN/src/msn_proto.h | 2 | ||||
-rw-r--r-- | protocols/MSN/src/msn_soapab.cpp | 8 |
2 files changed, 8 insertions, 2 deletions
diff --git a/protocols/MSN/src/msn_proto.h b/protocols/MSN/src/msn_proto.h index 2bc9a24bff..48d793a770 100644 --- a/protocols/MSN/src/msn_proto.h +++ b/protocols/MSN/src/msn_proto.h @@ -563,7 +563,7 @@ struct CMsnProto : public PROTO<CMsnProto> bool MSN_ABAddRemoveContact(const char* szCntId, int netId, bool add, bool allowRecurse = true);
unsigned MSN_ABContactAdd(const char* szEmail, const char* szNick, int netId, const char* szInvite, bool search, bool retry = false, bool allowRecurse = true);
void MSN_ABUpdateDynamicItem(bool allowRecurse = true);
- bool MSN_ABRefreshClist(void);
+ bool MSN_ABRefreshClist(unsigned int nTry=0);
ezxml_t abSoapHdr(const char* service, const char* scenario, ezxml_t& tbdy, char*& httphdr);
char* GetABHost(const char* service, bool isSharing);
diff --git a/protocols/MSN/src/msn_soapab.cpp b/protocols/MSN/src/msn_soapab.cpp index e0cd772cad..be9c914710 100644 --- a/protocols/MSN/src/msn_soapab.cpp +++ b/protocols/MSN/src/msn_soapab.cpp @@ -839,7 +839,7 @@ bool CMsnProto::MSN_ABFind(const char* szMethod, const char* szGuid, bool deltas return status == 200;
}
-bool CMsnProto::MSN_ABRefreshClist(void)
+bool CMsnProto::MSN_ABRefreshClist(unsigned int nTry)
{
NETLIBHTTPREQUEST nlhr = { 0 };
NETLIBHTTPHEADER headers[2];
@@ -939,6 +939,12 @@ bool CMsnProto::MSN_ABRefreshClist(void) }
ezxml_free(xmlm);
}
+ } else if (nlhrReply->resultCode == 400 && !nTry) {
+ // FIXME: No idea how to properly refresh WLSSC cookie required, therefore
+ // complete relogin :( For this we nuke auth token so that relogin is encforeced
+ // until we have a better solution
+ authSkypeComToken.Clear();
+ if (MSN_AuthOAuth() > 0) return MSN_ABRefreshClist(1);
}
CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)nlhrReply);
} else hHttpsConnection = NULL;
|