diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2021-02-01 22:12:13 +0200 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2021-02-01 22:28:15 +0200 |
commit | 609a26b59a82bb8dfa5722b5f8ea6c42014360d2 (patch) | |
tree | 6a362b94a06ced7a8b063d7e5c86ce751800c2b3 /indra/llcorehttp | |
parent | eac0f1857c6e8e89be649b60dcd8dca7573933df (diff) | |
parent | 21565a1f3fe1ae737e2f91c58be2c3cb0b5a2fec (diff) |
Merge branch 'master' of https://bitbucket.org/lindenlab/viewer/src/master into DRTVWR-515-maint
# Conflicts:
# autobuild.xml (llca)
# indra/llwindow/llwindow.h (SL-13507 vs SL-5894)
# indra/newview/llscenemonitor.cpp (SL-14422)
# indra/newview/llvovolume.cpp (SL-12069)
Diffstat (limited to 'indra/llcorehttp')
-rw-r--r-- | indra/llcorehttp/_httpoprequest.cpp | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/indra/llcorehttp/_httpoprequest.cpp b/indra/llcorehttp/_httpoprequest.cpp index 7bea8e9f9c..ba31290c24 100644 --- a/indra/llcorehttp/_httpoprequest.cpp +++ b/indra/llcorehttp/_httpoprequest.cpp @@ -567,16 +567,9 @@ HttpStatus HttpOpRequest::prepareRequest(HttpService * service) // Use the viewer-based thread-safe API which has a // fast/safe check for proxy enable. Would like to // encapsulate this someway... - if (LLProxy::instanceExists()) - { - // Make sure proxy won't be initialized from here, - // it might conflict with LLStartUp::startLLProxy() - LLProxy::getInstance()->applyProxySettings(mCurlHandle); - } - else - { - LL_WARNS() << "Proxy is not initialized!" << LL_ENDL; - } + // Make sure proxy won't be getInstance() from here, + // it is not thread safe + LLProxy::applyProxySettings(mCurlHandle); } else if (gpolicy.mHttpProxy.size()) @@ -817,6 +810,7 @@ size_t HttpOpRequest::readCallback(void * data, size_t size, size_t nmemb, void const size_t do_size((std::min)(req_size, body_size - op->mCurlBodyPos)); const size_t read_size(op->mReqBody->read(op->mCurlBodyPos, static_cast<char *>(data), do_size)); + // FIXME: singleton's instance() is Thread unsafe! Even if stats accumulators inside are. HTTPStats::instance().recordDataUp(read_size); op->mCurlBodyPos += read_size; return read_size; |