From e212cc9bf5a59c6ddb3a2aae11bb4e6a0618a21c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20P=C3=B6sel?= Date: Wed, 25 Nov 2015 20:48:44 +0000 Subject: Facebook: Attempt to fix problem with login for some people git-svn-id: http://svn.miranda-ng.org/main/trunk@15779 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/FacebookRM/src/communication.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/protocols/FacebookRM/src/communication.cpp b/protocols/FacebookRM/src/communication.cpp index b9d7a9d980..34fcaa7735 100644 --- a/protocols/FacebookRM/src/communication.cpp +++ b/protocols/FacebookRM/src/communication.cpp @@ -39,8 +39,10 @@ http::response facebook_client::flap(RequestType request_type, std::string *post // Prepare the request NETLIBHTTPREQUEST nlhr = { sizeof(NETLIBHTTPREQUEST) }; + std::string server = choose_server(request_type); + // Set request URL - std::string url = HTTP_PROTO_SECURE + choose_server(request_type) + choose_action(request_type, get_data); + std::string url = HTTP_PROTO_SECURE + server + choose_action(request_type, get_data); if (!parent->m_locale.empty()) url += "&locale=" + parent->m_locale; @@ -72,6 +74,10 @@ http::response facebook_client::flap(RequestType request_type, std::string *post // Set flags nlhr.flags = NLHRF_HTTP11 | NLHRF_SSL; + if (server == FACEBOOK_SERVER_MOBILE) { + nlhr.flags |= NLHRF_REDIRECT; + } + #ifdef _DEBUG nlhr.flags |= NLHRF_DUMPASTEXT; #else -- cgit v1.2.3