diff options
author | Rider Linden <rider@lindenlab.com> | 2015-10-14 17:46:24 -0700 |
---|---|---|
committer | Rider Linden <rider@lindenlab.com> | 2015-10-14 17:46:24 -0700 |
commit | bbb9d4f21b018bfffc41f790aab7b54975504027 (patch) | |
tree | 4c81cfc2348dd98a4a157979afc854568da4caea /indra/llmessage/llhttpsdhandler.cpp | |
parent | 53b947e0397d6b88fdc6c0a10144e5a6d02a67d3 (diff) |
MAINT-5732: Change to the way event polling handles error conditions and cancel calls.
Refactor any remaining LLCore::HTTPHandlers to use boost::shared_ptr
Started minor refactor in the materials manager into coroutines (unfinished)
Diffstat (limited to 'indra/llmessage/llhttpsdhandler.cpp')
-rw-r--r-- | indra/llmessage/llhttpsdhandler.cpp | 30 |
1 files changed, 1 insertions, 29 deletions
diff --git a/indra/llmessage/llhttpsdhandler.cpp b/indra/llmessage/llhttpsdhandler.cpp index d99bdd3f66..648bc5cfd8 100644 --- a/indra/llmessage/llhttpsdhandler.cpp +++ b/indra/llmessage/llhttpsdhandler.cpp @@ -36,8 +36,7 @@ #include "llcorehttputil.h" //======================================================================== -LLHttpSDHandler::LLHttpSDHandler(bool selfDelete): - mSelfDelete(selfDelete) +LLHttpSDHandler::LLHttpSDHandler() { } @@ -75,31 +74,4 @@ void LLHttpSDHandler::onCompleted(LLCore::HttpHandle handle, LLCore::HttpRespons this->onSuccess(response, resplsd); } - // The handler must destroy itself when it is done. - // *TODO: I'm not fond of this pattern. A class shooting itself in the head - // outside of a smart pointer always makes me nervous. - if (mSelfDelete) - delete this; -} - -//======================================================================== -LLHttpSDGenericHandler::LLHttpSDGenericHandler(const std::string &name, bool selfDelete): - LLHttpSDHandler(selfDelete), - mName(name) -{ -} - -void LLHttpSDGenericHandler::onSuccess(LLCore::HttpResponse * response, const LLSD &content) -{ - LL_DEBUGS() << mName << " Success." << LL_ENDL; -} - -void LLHttpSDGenericHandler::onFailure(LLCore::HttpResponse * response, LLCore::HttpStatus status) -{ - LL_WARNS() - << "\n--------------------------------------------------------------------------\n" - << mName << " Error[" << status.toULong() << "] cannot access cap with url '" - << response->getRequestURL() << "' because " << status.toString() - << "\n--------------------------------------------------------------------------" - << LL_ENDL; } |