diff options
Diffstat (limited to 'indra/viewer_components/login/lllogin.cpp')
-rwxr-xr-x | indra/viewer_components/login/lllogin.cpp | 46 |
1 files changed, 21 insertions, 25 deletions
diff --git a/indra/viewer_components/login/lllogin.cpp b/indra/viewer_components/login/lllogin.cpp index 27c91e2c14..ae327a26d2 100755 --- a/indra/viewer_components/login/lllogin.cpp +++ b/indra/viewer_components/login/lllogin.cpp @@ -117,8 +117,7 @@ private: void LLLogin::Impl::connect(const std::string& uri, const LLSD& login_params) { - // BUG-2707? - //LL_DEBUGS("LLLogin") << " connect with uri '" << uri << "', login_params " << login_params << LL_ENDL; + LL_DEBUGS("LLLogin") << " connect with uri '" << uri << "', login_params " << login_params << LL_ENDL; // Launch a coroutine with our login_() method. Run the coroutine until // its first wait; at that point, return here. @@ -126,8 +125,7 @@ void LLLogin::Impl::connect(const std::string& uri, const LLSD& login_params) LLCoros::instance().launch("LLLogin::Impl::login_", boost::bind(&Impl::login_, this, _1, uri, login_params)); - // BUG-2707? - //LL_DEBUGS("LLLogin") << " connected with uri '" << uri << "', login_params " << login_params << LL_ENDL; + LL_DEBUGS("LLLogin") << " connected with uri '" << uri << "', login_params " << login_params << LL_ENDL; } void LLLogin::Impl::login_(LLCoros::self& self, std::string uri, LLSD login_params) @@ -142,9 +140,8 @@ void LLLogin::Impl::login_(LLCoros::self& self, std::string uri, LLSD login_para //} // // -// BUG-2707? -// LL_DEBUGS("LLLogin") << "Entering coroutine " << LLCoros::instance().getName(self) -// << " with uri '" << uri << "', parameters " << printable_params << LL_ENDL; + LL_DEBUGS("LLLogin") << "Entering coroutine " << LLCoros::instance().getName(self) + << " with uri '" << uri << "', parameters " << printable_params << LL_ENDL; // Arriving in SRVRequest state LLEventStream replyPump("SRVreply", true); @@ -152,25 +149,24 @@ void LLLogin::Impl::login_(LLCoros::self& self, std::string uri, LLSD login_para LLSD rewrittenURIs; { - LLEventTimeout filter(replyPump); - sendProgressEvent("offline", "srvrequest"); + LLEventTimeout filter(replyPump); + sendProgressEvent("offline", "srvrequest"); - // Request SRV record. - // BUG-2707? - //LL_DEBUGS("LLLogin") << "Requesting SRV record from " << uri << LL_ENDL; + // Request SRV record. + LL_DEBUGS("LLLogin") << "Requesting SRV record from " << uri << LL_ENDL; - - // *NOTE:Mani - Completely arbitrary default timeout value for SRV request. + // *NOTE:Mani - Completely arbitrary default timeout value for SRV request. F32 seconds_to_timeout = 5.0f; if(login_params.has("cfg_srv_timeout")) { seconds_to_timeout = login_params["cfg_srv_timeout"].asReal(); } - // If the SRV request times out (e.g. EXT-3934), simulate response: an - // array containing our original URI. - LLSD fakeResponse(LLSD::emptyArray()); - fakeResponse.append(uri); + // If the SRV request times out (e.g. EXT-3934), simulate response: an + // array containing our original URI. + LLSD fakeResponse(LLSD::emptyArray()); + fakeResponse.append(uri); + filter.eventAfter(seconds_to_timeout, fakeResponse); std::string srv_pump_name = "LLAres"; @@ -180,13 +176,13 @@ void LLLogin::Impl::login_(LLCoros::self& self, std::string uri, LLSD login_para } // Make request - LLSD request; - request["op"] = "rewriteURI"; - request["uri"] = uri; - request["reply"] = replyPump.getName(); - rewrittenURIs = postAndWait(self, request, srv_pump_name, filter); - // EXP-772: If rewrittenURIs fail, try original URI as a fallback. - rewrittenURIs.append(uri); + LLSD request; + request["op"] = "rewriteURI"; + request["uri"] = uri; + request["reply"] = replyPump.getName(); + rewrittenURIs = postAndWait(self, request, srv_pump_name, filter); + // EXP-772: If rewrittenURIs fail, try original URI as a fallback. + rewrittenURIs.append(uri); } // we no longer need the filter LLEventPump& xmlrpcPump(LLEventPumps::instance().obtain("LLXMLRPCTransaction")); |