diff options
author | Euclid Linden <euclid@lindenlab.com> | 2022-05-05 16:07:46 +0000 |
---|---|---|
committer | Euclid Linden <euclid@lindenlab.com> | 2022-05-05 16:07:46 +0000 |
commit | 3f58ec2fdfb76ce2160884a3e97be49f60b6ac90 (patch) | |
tree | 855d7a4e9e9d082ff37eaf0e6f74d334c00c82c2 /indra/viewer_components | |
parent | e71201ac125cab5f3d3cf7d6a30500253fc29d90 (diff) | |
parent | ac10b104266f37aad1fdb9a9a2e93f0f847e8fb2 (diff) |
Merged in DV528-merge-6.5.6 (pull request #970)
DRTVWR-528 merge up to 6.5.6
Diffstat (limited to 'indra/viewer_components')
-rw-r--r-- | indra/viewer_components/login/lllogin.cpp | 33 |
1 files changed, 22 insertions, 11 deletions
diff --git a/indra/viewer_components/login/lllogin.cpp b/indra/viewer_components/login/lllogin.cpp index 168880dc12..8a7e6407ed 100644 --- a/indra/viewer_components/login/lllogin.cpp +++ b/indra/viewer_components/login/lllogin.cpp @@ -251,20 +251,31 @@ void LLLogin::Impl::loginCoro(std::string uri, LLSD login_params) // Since sSyncPoint is an LLEventMailDrop, we DEFINITELY want to // consume the posted event. LLCoros::OverrideConsuming oc(true); - // Timeout should produce the isUndefined() object passed here. - LL_DEBUGS("LLLogin") << "Login failure, waiting for sync from updater" << LL_ENDL; - LLSD updater = llcoro::suspendUntilEventOnWithTimeout(sSyncPoint, 10, LLSD()); - if (updater.isUndefined()) - { - LL_WARNS("LLLogin") << "Failed to hear from updater, proceeding with fail.login" - << LL_ENDL; - } - else + LLSD responses(mAuthResponse["responses"]); + LLSD updater; + + if (printable_params["wait_for_updater"].asBoolean()) { - LL_DEBUGS("LLLogin") << "Got responses from updater and login.cgi" << LL_ENDL; + std::string reason_response = responses["data"]["reason"].asString(); + if (reason_response == "update") // No point waiting if not an update + { + // Timeout should produce the isUndefined() object passed here. + LL_INFOS("LLLogin") << "Login failure, waiting for sync from updater" << LL_ENDL; + updater = llcoro::suspendUntilEventOnWithTimeout(sSyncPoint, 10, LLSD()); + + if (updater.isUndefined()) + { + LL_WARNS("LLLogin") << "Failed to hear from updater, proceeding with fail.login" + << LL_ENDL; + } + else + { + LL_DEBUGS("LLLogin") << "Got responses from updater and login.cgi" << LL_ENDL; + } + } } + // Let the fail.login handler deal with empty updater response. - LLSD responses(mAuthResponse["responses"]); responses["updater"] = updater; sendProgressEvent("offline", "fail.login", responses); } |