diff options
Diffstat (limited to 'indra/newview')
50 files changed, 224 insertions, 191 deletions
diff --git a/indra/newview/llaccountingcostmanager.cpp b/indra/newview/llaccountingcostmanager.cpp index 8767955fcb..7662a9689d 100644 --- a/indra/newview/llaccountingcostmanager.cpp +++ b/indra/newview/llaccountingcostmanager.cpp @@ -56,9 +56,9 @@ public: } } - void error( U32 statusNum, const std::string& reason ) + void errorWithContent( U32 statusNum, const std::string& reason, const LLSD& content ) { - llwarns << "Transport error "<<reason<<llendl; + llwarns << "Transport error [status:" << statusNum << "]: " << content <<llendl; clearPendingRequests(); LLAccountingCostObserver* observer = mObserverHandle.get(); diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index 99b79aadc4..20954e4bae 100755 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -2551,7 +2551,7 @@ public: virtual ~LLMaturityPreferencesResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); protected: @@ -2589,11 +2589,11 @@ void LLMaturityPreferencesResponder::result(const LLSD &pContent) mAgent->handlePreferredMaturityResult(actualMaturity); } -void LLMaturityPreferencesResponder::error(U32 pStatus, const std::string& pReason) +void LLMaturityPreferencesResponder::errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent) { llwarns << "while attempting to change maturity preference from '" << LLViewerRegion::accessToString(mPreviousMaturity) - << "' to '" << LLViewerRegion::accessToString(mPreferredMaturity) << "', we got an error because '" - << pReason << "' [status:" << pStatus << "]" << llendl; + << "' to '" << LLViewerRegion::accessToString(mPreferredMaturity) << "', we got an error with [status:" + << pStatus << "]: " << (pContent.isDefined() ? pContent : LLSD(pReason)) << llendl; mAgent->handlePreferredMaturityError(); } @@ -2783,7 +2783,7 @@ void LLAgent::sendMaturityPreferenceToServer(U8 pPreferredMaturity) // If we don't have a region, report it as an error if (getRegion() == NULL) { - responderPtr->error(0U, "region is not defined"); + responderPtr->errorWithContent(0U, "region is not defined", LLSD()); } else { @@ -2793,7 +2793,8 @@ void LLAgent::sendMaturityPreferenceToServer(U8 pPreferredMaturity) // If the capability is not defined, report it as an error if (url.empty()) { - responderPtr->error(0U, "capability 'UpdateAgentInformation' is not defined for region"); + responderPtr->errorWithContent(0U, + "capability 'UpdateAgentInformation' is not defined for region", LLSD()); } else { diff --git a/indra/newview/llagentpilot.cpp b/indra/newview/llagentpilot.cpp index 734c502fcf..c7872fc5f6 100644 --- a/indra/newview/llagentpilot.cpp +++ b/indra/newview/llagentpilot.cpp @@ -139,7 +139,7 @@ void LLAgentPilot::loadXML(const std::string& filename) mActions.reset(); LLSD record; - while (!file.eof() && LLSDSerialize::fromXML(record, file)) + while (!file.eof() && LLSDParser::PARSE_FAILURE != LLSDSerialize::fromXML(record, file)) { Action action; action.mTime = record["time"].asReal(); diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp index 1561f8d74c..2c76efc7fb 100755 --- a/indra/newview/llappearancemgr.cpp +++ b/indra/newview/llappearancemgr.cpp @@ -3308,10 +3308,10 @@ public: app_mgr->mLastUpdateRequestCOFVersion = new_version; } - virtual void error(U32 pStatus, const std::string& pReason) + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& content) { - llwarns << "While attempting to increment the agent's cof we got an error because '" - << pReason << "' [status:" << pStatus << "]" << llendl; + llwarns << "While attempting to increment the agent's cof we got an error with [status:" + << pStatus << "]: " << content << llendl; F32 seconds_to_wait; if (mRetryPolicy->shouldRetry(pStatus,seconds_to_wait)) { diff --git a/indra/newview/llassetuploadqueue.cpp b/indra/newview/llassetuploadqueue.cpp index f943759bb8..4bdb690225 100644 --- a/indra/newview/llassetuploadqueue.cpp +++ b/indra/newview/llassetuploadqueue.cpp @@ -69,10 +69,11 @@ public: delete mData; } - virtual void error(U32 statusNum, const std::string& reason) + virtual void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llwarns << "Error: " << reason << llendl; - LLUpdateTaskInventoryResponder::error(statusNum, reason); + llwarns << "LLAssetUploadChainResponder Error [status:" + << statusNum << "]: " << content << llendl; + LLUpdateTaskInventoryResponder::errorWithContent(statusNum, reason, content); LLAssetUploadQueue *queue = mSupplier->get(); if (queue) { diff --git a/indra/newview/llassetuploadresponders.cpp b/indra/newview/llassetuploadresponders.cpp index 694bbdfb67..2564802387 100644 --- a/indra/newview/llassetuploadresponders.cpp +++ b/indra/newview/llassetuploadresponders.cpp @@ -225,10 +225,10 @@ LLAssetUploadResponder::~LLAssetUploadResponder() } // virtual -void LLAssetUploadResponder::error(U32 statusNum, const std::string& reason) +void LLAssetUploadResponder::errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llinfos << "LLAssetUploadResponder::error " << statusNum - << " reason: " << reason << llendl; + llinfos << "LLAssetUploadResponder::error [status:" + << statusNum << "]: " << content << llendl; LLSD args; switch(statusNum) { @@ -340,9 +340,9 @@ LLNewAgentInventoryResponder::LLNewAgentInventoryResponder( } // virtual -void LLNewAgentInventoryResponder::error(U32 statusNum, const std::string& reason) +void LLNewAgentInventoryResponder::errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - LLAssetUploadResponder::error(statusNum, reason); + LLAssetUploadResponder::errorWithContent(statusNum, reason, content); //LLImportColladaAssetCache::getInstance()->assetUploaded(mVFileID, LLUUID(), FALSE); } @@ -487,9 +487,10 @@ void LLSendTexLayerResponder::uploadComplete(const LLSD& content) } } -void LLSendTexLayerResponder::error(U32 statusNum, const std::string& reason) +void LLSendTexLayerResponder::errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llinfos << "status: " << statusNum << " reason: " << reason << llendl; + llinfos << "LLSendTexLayerResponder error [status:" + << statusNum << "]: " << content << llendl; // Invoke the original callback with an error result LLViewerTexLayerSetBuffer::onTextureUploadComplete(LLUUID(), (void*) mBakedUploadData, -1, LL_EXSTAT_NONE); diff --git a/indra/newview/llassetuploadresponders.h b/indra/newview/llassetuploadresponders.h index 381b919c4a..a6d1016136 100644 --- a/indra/newview/llassetuploadresponders.h +++ b/indra/newview/llassetuploadresponders.h @@ -42,7 +42,7 @@ public: LLAssetType::EType asset_type); ~LLAssetUploadResponder(); - virtual void error(U32 statusNum, const std::string& reason); + virtual void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content); virtual void result(const LLSD& content); virtual void uploadUpload(const LLSD& content); virtual void uploadComplete(const LLSD& content); @@ -67,7 +67,7 @@ public: const LLSD& post_data, const std::string& file_name, LLAssetType::EType asset_type); - virtual void error(U32 statusNum, const std::string& reason); + virtual void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content); virtual void uploadComplete(const LLSD& content); virtual void uploadFailure(const LLSD& content); }; @@ -122,7 +122,7 @@ public: ~LLSendTexLayerResponder(); virtual void uploadComplete(const LLSD& content); - virtual void error(U32 statusNum, const std::string& reason); + virtual void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content); LLBakedUploadData * mBakedUploadData; }; diff --git a/indra/newview/llclassifiedstatsresponder.cpp b/indra/newview/llclassifiedstatsresponder.cpp index b4da31895f..e3cd83e174 100644 --- a/indra/newview/llclassifiedstatsresponder.cpp +++ b/indra/newview/llclassifiedstatsresponder.cpp @@ -62,8 +62,7 @@ void LLClassifiedStatsResponder::result(const LLSD& content) } /*virtual*/ -void LLClassifiedStatsResponder::error(U32 status, const std::string& reason) +void LLClassifiedStatsResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llinfos << "LLClassifiedStatsResponder::error(" - << status << ": " << reason << ")" << llendl; + llinfos << "LLClassifiedStatsResponder::error [status:" << status << "]: " << content << llendl; } diff --git a/indra/newview/llclassifiedstatsresponder.h b/indra/newview/llclassifiedstatsresponder.h index 3db1868cb2..06dcb62fd0 100644 --- a/indra/newview/llclassifiedstatsresponder.h +++ b/indra/newview/llclassifiedstatsresponder.h @@ -39,7 +39,7 @@ public: virtual void result(const LLSD& content); //If we get back an error (not found, etc...), handle it here - virtual void error(U32 status, const std::string& reason); + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); protected: LLUUID mClassifiedID; diff --git a/indra/newview/llestateinfomodel.cpp b/indra/newview/llestateinfomodel.cpp index 0faa888398..2669b0340f 100644 --- a/indra/newview/llestateinfomodel.cpp +++ b/indra/newview/llestateinfomodel.cpp @@ -122,9 +122,9 @@ public: } // if we get an error response - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Failed to commit estate info (" << status << "): " << reason << llendl; + llwarns << "Failed to commit estate info [status:" << status << "]: " << content << llendl; } }; diff --git a/indra/newview/lleventpoll.cpp b/indra/newview/lleventpoll.cpp index 2c786b7f8b..e0f7223a8c 100644 --- a/indra/newview/lleventpoll.cpp +++ b/indra/newview/lleventpoll.cpp @@ -62,7 +62,7 @@ namespace void handleMessage(const LLSD& content); - virtual void error(U32 status, const std::string& reason); + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); virtual void result(const LLSD& content); virtual void completedRaw(U32 status, @@ -187,7 +187,7 @@ namespace } //virtual - void LLEventPollResponder::error(U32 status, const std::string& reason) + void LLEventPollResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { if (mDone) return; @@ -207,13 +207,13 @@ namespace + mErrorCount * EVENT_POLL_ERROR_RETRY_SECONDS_INC , this); - llwarns << "Unexpected HTTP error. status: " << status << ", reason: " << reason << llendl; + llwarns << "LLEventPollResponder error [status:" << status << "]: " << content << llendl; } else { - llwarns << "LLEventPollResponder::error: <" << mCount << "> got " - << status << ": " << reason - << (mDone ? " -- done" : "") << llendl; + llwarns << "LLEventPollResponder error <" << mCount + << "> [status:" << status << "]: " << content + << (mDone ? " -- done" : "") << llendl; stop(); // At this point we have given up and the viewer will not receive HTTP messages from the simulator. diff --git a/indra/newview/llfasttimerview.cpp b/indra/newview/llfasttimerview.cpp index 19fca9b95d..fbf72b1a85 100644 --- a/indra/newview/llfasttimerview.cpp +++ b/indra/newview/llfasttimerview.cpp @@ -1070,7 +1070,7 @@ void LLFastTimerView::exportCharts(const std::string& base, const std::string& t { //read base log into memory S32 i = 0; std::ifstream is(base.c_str()); - while (!is.eof() && LLSDSerialize::fromXML(cur, is)) + while (!is.eof() && LLSDParser::PARSE_FAILURE != LLSDSerialize::fromXML(cur, is)) { base_data[i++] = cur; } @@ -1083,7 +1083,7 @@ void LLFastTimerView::exportCharts(const std::string& base, const std::string& t { //read current log into memory S32 i = 0; std::ifstream is(target.c_str()); - while (!is.eof() && LLSDSerialize::fromXML(cur, is)) + while (!is.eof() && LLSDParser::PARSE_FAILURE != LLSDSerialize::fromXML(cur, is)) { cur_data[i++] = cur; @@ -1374,7 +1374,7 @@ LLSD LLFastTimerView::analyzePerformanceLogDefault(std::istream& is) stats_map_t time_stats; stats_map_t sample_stats; - while (!is.eof() && LLSDSerialize::fromXML(cur, is)) + while (!is.eof() && LLSDParser::PARSE_FAILURE != LLSDSerialize::fromXML(cur, is)) { for (LLSD::map_iterator iter = cur.beginMap(); iter != cur.endMap(); ++iter) { diff --git a/indra/newview/llfloateravatarpicker.cpp b/indra/newview/llfloateravatarpicker.cpp index 0290e7cdf0..752aba5e16 100644 --- a/indra/newview/llfloateravatarpicker.cpp +++ b/indra/newview/llfloateravatarpicker.cpp @@ -404,8 +404,7 @@ public: } else { - llinfos << "avatar picker failed " << status - << " reason " << reason << llendl; + llwarns << "avatar picker failed [status:" << status << "]: " << content << llendl; } } diff --git a/indra/newview/llfloaterregiondebugconsole.cpp b/indra/newview/llfloaterregiondebugconsole.cpp index c7fab2573f..0cde878055 100644 --- a/indra/newview/llfloaterregiondebugconsole.cpp +++ b/indra/newview/llfloaterregiondebugconsole.cpp @@ -75,7 +75,7 @@ namespace { public: /* virtual */ - void error(U32 status, const std::string& reason) + void errorWithContent(U32 status, const std::string& reason) { sConsoleReplySignal(UNABLE_TO_SEND_COMMAND); } diff --git a/indra/newview/llfloaterregioninfo.cpp b/indra/newview/llfloaterregioninfo.cpp index a36021f971..4a9ea5acf0 100644 --- a/indra/newview/llfloaterregioninfo.cpp +++ b/indra/newview/llfloaterregioninfo.cpp @@ -756,9 +756,10 @@ class ConsoleRequestResponder : public LLHTTPClient::Responder { public: /*virtual*/ - void error(U32 status, const std::string& reason) + void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "requesting mesh_rez_enabled failed" << llendl; + llwarns << "ConsoleRequestResponder error requesting mesh_rez_enabled [status:" + << status << "]: " << content << llendl; } }; @@ -768,9 +769,10 @@ class ConsoleUpdateResponder : public LLHTTPClient::Responder { public: /* virtual */ - void error(U32 status, const std::string& reason) + void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Updating mesh enabled region setting failed" << llendl; + llwarns << "ConsoleRequestResponder error updating mesh enabled region setting [status:" + << status << "]: " << content << llendl; } }; @@ -2207,10 +2209,10 @@ public: } // if we get an error response - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llinfos << "LLEstateChangeInfoResponder::error " - << status << ": " << reason << llendl; + llinfos << "LLEstateChangeInfoResponder::error [status:" + << status << "]: " << content << llendl; } private: LLHandle<LLPanel> mpPanel; diff --git a/indra/newview/llfloaterreporter.cpp b/indra/newview/llfloaterreporter.cpp index 86bd15b217..685b566fa8 100644 --- a/indra/newview/llfloaterreporter.cpp +++ b/indra/newview/llfloaterreporter.cpp @@ -695,7 +695,7 @@ class LLUserReportResponder : public LLHTTPClient::Responder public: LLUserReportResponder(): LLHTTPClient::Responder() {} - void error(U32 status, const std::string& reason) + void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { // *TODO do some user messaging here LLUploadDialog::modalUploadFinished(); diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp index a50907601c..17c34f1da0 100644 --- a/indra/newview/llfloaterscriptlimits.cpp +++ b/indra/newview/llfloaterscriptlimits.cpp @@ -221,9 +221,9 @@ void fetchScriptLimitsRegionInfoResponder::result(const LLSD& content) } } -void fetchScriptLimitsRegionInfoResponder::error(U32 status, const std::string& reason) +void fetchScriptLimitsRegionInfoResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Error from responder " << reason << llendl; + llwarns << "fetchScriptLimitsRegionInfoResponder error [status:" << status << "]: " << content << llendl; } void fetchScriptLimitsRegionSummaryResponder::result(const LLSD& content_ref) @@ -308,9 +308,9 @@ void fetchScriptLimitsRegionSummaryResponder::result(const LLSD& content_ref) } } -void fetchScriptLimitsRegionSummaryResponder::error(U32 status, const std::string& reason) +void fetchScriptLimitsRegionSummaryResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Error from responder " << reason << llendl; + llwarns << "fetchScriptLimitsRegionSummaryResponder error [status:" << status << "]: " << content << llendl; } void fetchScriptLimitsRegionDetailsResponder::result(const LLSD& content_ref) @@ -417,9 +417,9 @@ result (map) } } -void fetchScriptLimitsRegionDetailsResponder::error(U32 status, const std::string& reason) +void fetchScriptLimitsRegionDetailsResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Error from responder " << reason << llendl; + llwarns << "fetchScriptLimitsRegionDetailsResponder error [status:" << status << "]: " << content << llendl; } void fetchScriptLimitsAttachmentInfoResponder::result(const LLSD& content_ref) @@ -513,9 +513,9 @@ void fetchScriptLimitsAttachmentInfoResponder::result(const LLSD& content_ref) } } -void fetchScriptLimitsAttachmentInfoResponder::error(U32 status, const std::string& reason) +void fetchScriptLimitsAttachmentInfoResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "Error from responder " << reason << llendl; + llwarns << "fetchScriptLimitsAttachmentInfoResponder error [status:" << status << "]: " << content << llendl; } ///---------------------------------------------------------------------------- diff --git a/indra/newview/llfloaterscriptlimits.h b/indra/newview/llfloaterscriptlimits.h index 9bcfa5fe14..f8732ef94b 100644 --- a/indra/newview/llfloaterscriptlimits.h +++ b/indra/newview/llfloaterscriptlimits.h @@ -89,7 +89,7 @@ class fetchScriptLimitsRegionInfoResponder: public LLHTTPClient::Responder fetchScriptLimitsRegionInfoResponder(const LLSD& info) : mInfo(info) {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); public: protected: LLSD mInfo; @@ -101,7 +101,7 @@ class fetchScriptLimitsRegionSummaryResponder: public LLHTTPClient::Responder fetchScriptLimitsRegionSummaryResponder(const LLSD& info) : mInfo(info) {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); public: protected: LLSD mInfo; @@ -113,7 +113,7 @@ class fetchScriptLimitsRegionDetailsResponder: public LLHTTPClient::Responder fetchScriptLimitsRegionDetailsResponder(const LLSD& info) : mInfo(info) {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); public: protected: LLSD mInfo; @@ -125,7 +125,7 @@ class fetchScriptLimitsAttachmentInfoResponder: public LLHTTPClient::Responder fetchScriptLimitsAttachmentInfoResponder() {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); public: protected: }; diff --git a/indra/newview/llgroupmgr.cpp b/indra/newview/llgroupmgr.cpp index 81eb1d397e..cbd844cdac 100644 --- a/indra/newview/llgroupmgr.cpp +++ b/indra/newview/llgroupmgr.cpp @@ -1847,14 +1847,15 @@ public: GroupMemberDataResponder() {} virtual ~GroupMemberDataResponder() {} virtual void result(const LLSD& pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); private: LLSD mMemberData; }; -void GroupMemberDataResponder::error(U32 pStatus, const std::string& pReason) +void GroupMemberDataResponder::errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent) { - LL_WARNS("GrpMgr") << "Error receiving group member data." << LL_ENDL; + LL_WARNS("GrpMgr") << "Error receiving group member data [status:" + << pStatus << "]: " << pContent << LL_ENDL; } void GroupMemberDataResponder::result(const LLSD& content) diff --git a/indra/newview/llhomelocationresponder.cpp b/indra/newview/llhomelocationresponder.cpp index 4850d18d99..37428c4a44 100644 --- a/indra/newview/llhomelocationresponder.cpp +++ b/indra/newview/llhomelocationresponder.cpp @@ -97,7 +97,7 @@ void LLHomeLocationResponder::result( const LLSD& content ) } } -void LLHomeLocationResponder::error( U32 status, const std::string& reason ) +void LLHomeLocationResponder::errorWithContent( U32 status, const std::string& reason, const LLSD& content ) { - llinfos << "received error(" << reason << ")" << llendl; + llwarns << "LLHomeLocationResponder error [status:" << status << "]: " << content << llendl; } diff --git a/indra/newview/llhomelocationresponder.h b/indra/newview/llhomelocationresponder.h index d640b9c894..9bf4b12c4e 100644 --- a/indra/newview/llhomelocationresponder.h +++ b/indra/newview/llhomelocationresponder.h @@ -36,7 +36,7 @@ class LLHomeLocationResponder : public LLHTTPClient::Responder { virtual void result( const LLSD& content ); - virtual void error( U32 status, const std::string& reason ); + virtual void errorWithContent( U32 status, const std::string& reason, const LLSD& content ); }; #endif diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 63eedcdfea..fff178f8fe 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -985,9 +985,10 @@ public: mSessionID = session_id; } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llinfos << "Error inviting all agents to session" << llendl; + llwarns << "Error inviting all agents to session [status:" + << statusNum << "]: " << content << llendl; //throw something back to the viewer here? } diff --git a/indra/newview/llimpanel.cpp b/indra/newview/llimpanel.cpp index 0250af6a0e..1dab0e67bf 100644 --- a/indra/newview/llimpanel.cpp +++ b/indra/newview/llimpanel.cpp @@ -394,9 +394,10 @@ public: mSessionID = session_id; } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llinfos << "Error inviting all agents to session" << llendl; + llwarns << "Error inviting all agents to session [status:" + << statusNum << "]: " << content << llendl; //throw something back to the viewer here? } diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 57373704ef..20b33c5d08 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -1227,7 +1227,7 @@ public: mAgents = agents_to_invite; } - virtual void error(U32 statusNum, const std::string& reason) + virtual void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { //try an "old school" way. if ( statusNum == 400 ) @@ -1239,6 +1239,9 @@ public: mAgents); } + llwarns << "LLStartConferenceChatResponder error [status:" + << statusNum << "]: " << content << llendl; + //else throw an error back to the client? //in theory we should have just have these error strings //etc. set up in this file as opposed to the IMMgr, @@ -1384,8 +1387,10 @@ public: } } - void error(U32 statusNum, const std::string& reason) - { + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) + { + llwarns << "LLViewerChatterBoxInvitationAcceptResponder error [status:" + << statusNum << "]: " << content << llendl; //throw something back to the viewer here? if ( gIMMgr ) { diff --git a/indra/newview/llinspectavatar.cpp b/indra/newview/llinspectavatar.cpp index 17d0b0ffbb..aafc43b02d 100644 --- a/indra/newview/llinspectavatar.cpp +++ b/indra/newview/llinspectavatar.cpp @@ -501,9 +501,9 @@ void LLInspectAvatar::toggleSelectedVoice(bool enabled) mSessionID = session_id; } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << status << ": " << reason << llendl; + llwarns << "MuteVoiceResponder error [status:" << status << "]: " << content << llendl; if ( gIMMgr ) { diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index ac1f40b486..99e72cdb22 100755 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -424,9 +424,10 @@ public: { } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("InvAPI") << "CreateInventoryCategory failed. status = " << status << ", reasion = \"" << reason << "\"" << LL_ENDL; + LL_WARNS("InvAPI") << "CreateInventoryCategory failed [status:" + << status << "]: " << content << LL_ENDL; } virtual void result(const LLSD& content) @@ -1399,10 +1400,9 @@ void LLInventoryModel::fetchInventoryResponder::result(const LLSD& content) } //If we get back an error (not found, etc...), handle it here -void LLInventoryModel::fetchInventoryResponder::error(U32 status, const std::string& reason) +void LLInventoryModel::fetchInventoryResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llinfos << "fetchInventory::error " - << status << ": " << reason << llendl; + llwarns << "fetchInventory error [status:" << status << "]: " << content << llendl; gInventory.notifyObservers(); } diff --git a/indra/newview/llinventorymodel.h b/indra/newview/llinventorymodel.h index 8382e875b4..dfdd237c95 100644 --- a/indra/newview/llinventorymodel.h +++ b/indra/newview/llinventorymodel.h @@ -84,7 +84,7 @@ public: public: fetchInventoryResponder(const LLSD& request_sd) : mRequestSD(request_sd) {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); protected: LLSD mRequestSD; }; diff --git a/indra/newview/llinventorymodelbackgroundfetch.cpp b/indra/newview/llinventorymodelbackgroundfetch.cpp index 024d34519f..f2b39e7186 100644 --- a/indra/newview/llinventorymodelbackgroundfetch.cpp +++ b/indra/newview/llinventorymodelbackgroundfetch.cpp @@ -366,7 +366,7 @@ class LLInventoryModelFetchItemResponder : public LLInventoryModel::fetchInvento public: LLInventoryModelFetchItemResponder(const LLSD& request_sd) : LLInventoryModel::fetchInventoryResponder(request_sd) {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); }; void LLInventoryModelFetchItemResponder::result( const LLSD& content ) @@ -375,9 +375,9 @@ void LLInventoryModelFetchItemResponder::result( const LLSD& content ) LLInventoryModelBackgroundFetch::instance().incrFetchCount(-1); } -void LLInventoryModelFetchItemResponder::error( U32 status, const std::string& reason ) +void LLInventoryModelFetchItemResponder::errorWithContent( U32 status, const std::string& reason, const LLSD& content ) { - LLInventoryModel::fetchInventoryResponder::error(status, reason); + LLInventoryModel::fetchInventoryResponder::errorWithContent(status, reason, content); LLInventoryModelBackgroundFetch::instance().incrFetchCount(-1); } @@ -391,7 +391,7 @@ public: {}; //LLInventoryModelFetchDescendentsResponder() {}; void result(const LLSD& content); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); protected: BOOL getIsRecursive(const LLUUID& cat_id) const; private: @@ -529,12 +529,12 @@ void LLInventoryModelFetchDescendentsResponder::result(const LLSD& content) } // If we get back an error (not found, etc...), handle it here. -void LLInventoryModelFetchDescendentsResponder::error(U32 status, const std::string& reason) +void LLInventoryModelFetchDescendentsResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { LLInventoryModelBackgroundFetch *fetcher = LLInventoryModelBackgroundFetch::getInstance(); - llinfos << "LLInventoryModelFetchDescendentsResponder::error " - << status << ": " << reason << llendl; + llinfos << "LLInventoryModelFetchDescendentsResponder::error [status:" + << status << "]: " << content << llendl; fetcher->incrFetchCount(-1); diff --git a/indra/newview/llmediadataclient.cpp b/indra/newview/llmediadataclient.cpp index 31038b4aac..e3b46d5d2f 100644 --- a/indra/newview/llmediadataclient.cpp +++ b/indra/newview/llmediadataclient.cpp @@ -564,7 +564,7 @@ LLMediaDataClient::Responder::Responder(const request_ptr_t &request) } /*virtual*/ -void LLMediaDataClient::Responder::error(U32 status, const std::string& reason) +void LLMediaDataClient::Responder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { mRequest->stopTracking(); @@ -596,8 +596,8 @@ void LLMediaDataClient::Responder::error(U32 status, const std::string& reason) } else { - std::string msg = boost::lexical_cast<std::string>(status) + ": " + reason; - LL_WARNS("LLMediaDataClient") << *mRequest << " http error(" << msg << ")" << LL_ENDL; + LL_WARNS("LLMediaDataClient") << *mRequest << " http error [status:" + << status << "]:" << content << ")" << LL_ENDL; } } @@ -1003,7 +1003,7 @@ LLMediaDataClient::Responder *LLObjectMediaNavigateClient::RequestNavigate::crea } /*virtual*/ -void LLObjectMediaNavigateClient::Responder::error(U32 status, const std::string& reason) +void LLObjectMediaNavigateClient::Responder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { getRequest()->stopTracking(); @@ -1017,7 +1017,7 @@ void LLObjectMediaNavigateClient::Responder::error(U32 status, const std::string // class if (status == HTTP_SERVICE_UNAVAILABLE) { - LLMediaDataClient::Responder::error(status, reason); + LLMediaDataClient::Responder::errorWithContent(status, reason, content); } else { diff --git a/indra/newview/llmediadataclient.h b/indra/newview/llmediadataclient.h index ab90915c55..89e20a28d0 100644 --- a/indra/newview/llmediadataclient.h +++ b/indra/newview/llmediadataclient.h @@ -195,7 +195,7 @@ protected: public: Responder(const request_ptr_t &request); //If we get back an error (not found, etc...), handle it here - virtual void error(U32 status, const std::string& reason); + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); //If we get back a normal response, handle it here. Default just logs it. virtual void result(const LLSD& content); @@ -400,7 +400,7 @@ protected: public: Responder(const request_ptr_t &request) : LLMediaDataClient::Responder(request) {} - virtual void error(U32 status, const std::string& reason); + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); virtual void result(const LLSD &content); private: void mediaNavigateBounceBack(); diff --git a/indra/newview/llpathfindingmanager.cpp b/indra/newview/llpathfindingmanager.cpp index 2dd01e931e..c277359133 100644 --- a/indra/newview/llpathfindingmanager.cpp +++ b/indra/newview/llpathfindingmanager.cpp @@ -108,7 +108,7 @@ public: virtual ~NavMeshStatusResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); protected: @@ -130,7 +130,7 @@ public: virtual ~NavMeshResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); protected: @@ -151,7 +151,7 @@ public: virtual ~AgentStateResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); protected: @@ -170,7 +170,7 @@ public: virtual ~NavMeshRebakeResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string& pReason); + virtual void errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent); protected: @@ -190,9 +190,11 @@ public: virtual ~LinksetsResponder(); void handleObjectLinksetsResult(const LLSD &pContent); - void handleObjectLinksetsError(U32 pStatus, const std::string &pReason, const std::string &pURL); + void handleObjectLinksetsError(U32 pStatus, const std::string &pReason, + const LLSD& pContent, const std::string &pURL); void handleTerrainLinksetsResult(const LLSD &pContent); - void handleTerrainLinksetsError(U32 pStatus, const std::string &pReason, const std::string &pURL); + void handleTerrainLinksetsError(U32 pStatus, const std::string &pReason, + const LLSD& pContent, const std::string &pURL); protected: @@ -230,7 +232,7 @@ public: virtual ~ObjectLinksetsResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string &pReason); + virtual void errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent); protected: @@ -250,7 +252,7 @@ public: virtual ~TerrainLinksetsResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string &pReason); + virtual void errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent); protected: @@ -270,7 +272,7 @@ public: virtual ~CharactersResponder(); virtual void result(const LLSD &pContent); - virtual void error(U32 pStatus, const std::string &pReason); + virtual void errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent); protected: @@ -800,9 +802,9 @@ void NavMeshStatusResponder::result(const LLSD &pContent) LLPathfindingManager::getInstance()->handleNavMeshStatusRequest(navMeshStatus, mRegion, mIsGetStatusOnly); } -void NavMeshStatusResponder::error(U32 pStatus, const std::string& pReason) +void NavMeshStatusResponder::errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent) { - llwarns << "error with request to URL '" << mCapabilityURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "NavMeshStatusResponder error [status:" << pStatus << "]: " << pContent << llendl; LLPathfindingNavMeshStatus navMeshStatus(mRegionUUID); LLPathfindingManager::getInstance()->handleNavMeshStatusRequest(navMeshStatus, mRegion, mIsGetStatusOnly); } @@ -828,9 +830,9 @@ void NavMeshResponder::result(const LLSD &pContent) mNavMeshPtr->handleNavMeshResult(pContent, mNavMeshVersion); } -void NavMeshResponder::error(U32 pStatus, const std::string& pReason) +void NavMeshResponder::errorWithContent(U32 pStatus, const std::string& pReason, const LLSD& pContent) { - mNavMeshPtr->handleNavMeshError(pStatus, pReason, mCapabilityURL, mNavMeshVersion); + mNavMeshPtr->handleNavMeshError(pStatus, pReason, pContent, mCapabilityURL, mNavMeshVersion); } //--------------------------------------------------------------------------- @@ -855,9 +857,9 @@ void AgentStateResponder::result(const LLSD &pContent) LLPathfindingManager::getInstance()->handleAgentState(canRebakeRegion); } -void AgentStateResponder::error(U32 pStatus, const std::string &pReason) +void AgentStateResponder::errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent) { - llwarns << "error with request to URL '" << mCapabilityURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "AgentStateResponder error [status:" << pStatus << "]: " << pContent << llendl; LLPathfindingManager::getInstance()->handleAgentState(FALSE); } @@ -881,9 +883,9 @@ void NavMeshRebakeResponder::result(const LLSD &pContent) mRebakeNavMeshCallback(true); } -void NavMeshRebakeResponder::error(U32 pStatus, const std::string &pReason) +void NavMeshRebakeResponder::errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent) { - llwarns << "error with request to URL '" << mCapabilityURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "NavMeshRebakeResponder error [status:" << pStatus << "]: " << pContent << llendl; mRebakeNavMeshCallback(false); } @@ -916,9 +918,11 @@ void LinksetsResponder::handleObjectLinksetsResult(const LLSD &pContent) } } -void LinksetsResponder::handleObjectLinksetsError(U32 pStatus, const std::string &pReason, const std::string &pURL) +void LinksetsResponder::handleObjectLinksetsError(U32 pStatus, const std::string &pReason, + const LLSD& pContent, const std::string &pURL) { - llwarns << "error with request to URL '" << pURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "LinksetsResponder object linksets error with request to URL '" << pURL << "' [status:" + << pStatus << "]: " << pContent << llendl; mObjectMessagingState = kReceivedError; if (mTerrainMessagingState != kWaiting) { @@ -937,8 +941,11 @@ void LinksetsResponder::handleTerrainLinksetsResult(const LLSD &pContent) } } -void LinksetsResponder::handleTerrainLinksetsError(U32 pStatus, const std::string &pReason, const std::string &pURL) +void LinksetsResponder::handleTerrainLinksetsError(U32 pStatus, const std::string &pReason, + const LLSD& pContent, const std::string &pURL) { + llwarns << "LinksetsResponder terrain linksets error with request to URL '" << pURL << "' [status:" + << pStatus << "]: " << pContent << llendl; mTerrainMessagingState = kReceivedError; if (mObjectMessagingState != kWaiting) { @@ -988,9 +995,9 @@ void ObjectLinksetsResponder::result(const LLSD &pContent) mLinksetsResponsderPtr->handleObjectLinksetsResult(pContent); } -void ObjectLinksetsResponder::error(U32 pStatus, const std::string &pReason) +void ObjectLinksetsResponder::errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent) { - mLinksetsResponsderPtr->handleObjectLinksetsError(pStatus, pReason, mCapabilityURL); + mLinksetsResponsderPtr->handleObjectLinksetsError(pStatus, pReason, pContent, mCapabilityURL); } //--------------------------------------------------------------------------- @@ -1013,9 +1020,9 @@ void TerrainLinksetsResponder::result(const LLSD &pContent) mLinksetsResponsderPtr->handleTerrainLinksetsResult(pContent); } -void TerrainLinksetsResponder::error(U32 pStatus, const std::string &pReason) +void TerrainLinksetsResponder::errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent) { - mLinksetsResponsderPtr->handleTerrainLinksetsError(pStatus, pReason, mCapabilityURL); + mLinksetsResponsderPtr->handleTerrainLinksetsError(pStatus, pReason, pContent, mCapabilityURL); } //--------------------------------------------------------------------------- @@ -1040,9 +1047,9 @@ void CharactersResponder::result(const LLSD &pContent) mCharactersCallback(mRequestId, LLPathfindingManager::kRequestCompleted, characterListPtr); } -void CharactersResponder::error(U32 pStatus, const std::string &pReason) +void CharactersResponder::errorWithContent(U32 pStatus, const std::string &pReason, const LLSD& pContent) { - llwarns << "error with request to URL '" << mCapabilityURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "CharactersResponder error [status:" << pStatus << "]: " << pContent << llendl; LLPathfindingObjectListPtr characterListPtr = LLPathfindingObjectListPtr(new LLPathfindingCharacterList()); mCharactersCallback(mRequestId, LLPathfindingManager::kRequestError, characterListPtr); diff --git a/indra/newview/llpathfindingnavmesh.cpp b/indra/newview/llpathfindingnavmesh.cpp index e01dd3a152..0c23e5ac92 100644 --- a/indra/newview/llpathfindingnavmesh.cpp +++ b/indra/newview/llpathfindingnavmesh.cpp @@ -184,9 +184,10 @@ void LLPathfindingNavMesh::handleNavMeshError() setRequestStatus(kNavMeshRequestError); } -void LLPathfindingNavMesh::handleNavMeshError(U32 pStatus, const std::string &pReason, const std::string &pURL, U32 pNavMeshVersion) +void LLPathfindingNavMesh::handleNavMeshError(U32 pStatus, const std::string &pReason, const LLSD& pContent, const std::string &pURL, U32 pNavMeshVersion) { - llwarns << "error with request to URL '" << pURL << "' because " << pReason << " (statusCode:" << pStatus << ")" << llendl; + llwarns << "LLPathfindingNavMesh error with request to URL '" << pURL << "' [status:" + << pStatus << "]: " << pContent << llendl; if (mNavMeshStatus.getVersion() == pNavMeshVersion) { handleNavMeshError(); diff --git a/indra/newview/llpathfindingnavmesh.h b/indra/newview/llpathfindingnavmesh.h index 7a844f54ce..b872ccad7c 100644 --- a/indra/newview/llpathfindingnavmesh.h +++ b/indra/newview/llpathfindingnavmesh.h @@ -74,7 +74,7 @@ public: void handleNavMeshResult(const LLSD &pContent, U32 pNavMeshVersion); void handleNavMeshNotEnabled(); void handleNavMeshError(); - void handleNavMeshError(U32 pStatus, const std::string &pReason, const std::string &pURL, U32 pNavMeshVersion); + void handleNavMeshError(U32 pStatus, const std::string &pReason, const LLSD& pContent, const std::string &pURL, U32 pNavMeshVersion); protected: diff --git a/indra/newview/llproductinforequest.cpp b/indra/newview/llproductinforequest.cpp index 93bf8b2328..1390000fc5 100644 --- a/indra/newview/llproductinforequest.cpp +++ b/indra/newview/llproductinforequest.cpp @@ -43,10 +43,10 @@ public: } //If we get back an error (not found, etc...), handle it here - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "LLProductInfoRequest::error(" - << status << ": " << reason << ")" << llendl; + llwarns << "LLProductInfoRequest error [status:" + << status << ":] " << content << llendl; } }; diff --git a/indra/newview/llremoteparcelrequest.cpp b/indra/newview/llremoteparcelrequest.cpp index 3862dac340..500dec7ee5 100644 --- a/indra/newview/llremoteparcelrequest.cpp +++ b/indra/newview/llremoteparcelrequest.cpp @@ -62,10 +62,10 @@ void LLRemoteParcelRequestResponder::result(const LLSD& content) //If we get back an error (not found, etc...), handle it here //virtual -void LLRemoteParcelRequestResponder::error(U32 status, const std::string& reason) +void LLRemoteParcelRequestResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llinfos << "LLRemoteParcelRequest::error(" - << status << ": " << reason << ")" << llendl; + llwarns << "LLRemoteParcelRequest error [status:" + << status << "]: " << content << llendl; // Panel inspecting the information may be closed and destroyed // before this response is received. diff --git a/indra/newview/llremoteparcelrequest.h b/indra/newview/llremoteparcelrequest.h index 74cf1616df..b87056573b 100644 --- a/indra/newview/llremoteparcelrequest.h +++ b/indra/newview/llremoteparcelrequest.h @@ -44,7 +44,7 @@ public: /*virtual*/ void result(const LLSD& content); //If we get back an error (not found, etc...), handle it here - /*virtual*/ void error(U32 status, const std::string& reason); + /*virtual*/ void errorWithContent(U32 status, const std::string& reason, const LLSD& content); protected: LLHandle<LLRemoteParcelInfoObserver> mObserverHandle; diff --git a/indra/newview/llspeakers.cpp b/indra/newview/llspeakers.cpp index 1c7c6450c7..890bc0f42d 100644 --- a/indra/newview/llspeakers.cpp +++ b/indra/newview/llspeakers.cpp @@ -726,9 +726,9 @@ public: mSessionID = session_id; } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << status << ": " << reason << llendl; + llwarns << "ModerationResponder error [status:" << status << "]: " << content << llendl; if ( gIMMgr ) { diff --git a/indra/newview/lluploadfloaterobservers.cpp b/indra/newview/lluploadfloaterobservers.cpp index 5a6a17fbca..1d777b3f7f 100644 --- a/indra/newview/lluploadfloaterobservers.cpp +++ b/indra/newview/lluploadfloaterobservers.cpp @@ -33,9 +33,10 @@ LLUploadModelPremissionsResponder::LLUploadModelPremissionsResponder(const LLHan { } -void LLUploadModelPremissionsResponder::error(U32 status, const std::string& reason) +void LLUploadModelPremissionsResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - llwarns << "LLUploadModelPremissionsResponder::error("<< status << ": " << reason << ")" << llendl; + llwarns << "LLUploadModelPremissionsResponder error [status:" + << status << "]: " << content << llendl; LLUploadPermissionsObserver* observer = mObserverHandle.get(); diff --git a/indra/newview/lluploadfloaterobservers.h b/indra/newview/lluploadfloaterobservers.h index 79aad282d7..b43ddb44d9 100644 --- a/indra/newview/lluploadfloaterobservers.h +++ b/indra/newview/lluploadfloaterobservers.h @@ -86,7 +86,7 @@ public: LLUploadModelPremissionsResponder(const LLHandle<LLUploadPermissionsObserver>& observer); - void error(U32 status, const std::string& reason); + void errorWithContent(U32 status, const std::string& reason, const LLSD& content); void result(const LLSD& content); diff --git a/indra/newview/llviewerdisplayname.cpp b/indra/newview/llviewerdisplayname.cpp index 5741fab29a..1ac6a90894 100644 --- a/indra/newview/llviewerdisplayname.cpp +++ b/indra/newview/llviewerdisplayname.cpp @@ -59,8 +59,10 @@ class LLSetDisplayNameResponder : public LLHTTPClient::Responder { public: // only care about errors - /*virtual*/ void error(U32 status, const std::string& reason) + /*virtual*/ void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { + llwarns << "LLSetDisplayNameResponder error [status:" + << status << "]: " << content << llendl; LLViewerDisplayName::sSetDisplayNameSignal(false, "", LLSD()); LLViewerDisplayName::sSetDisplayNameSignal.disconnect_all_slots(); } diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp index eec44c7a74..0561e731e7 100644 --- a/indra/newview/llviewerobjectlist.cpp +++ b/indra/newview/llviewerobjectlist.cpp @@ -691,12 +691,12 @@ public: } } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { llwarns << "Transport error requesting object cost " - << "HTTP status: " << statusNum << ", reason: " - << reason << "." << llendl; + << "[status: " << statusNum << "]: " + << content << llendl; // TODO*: Error message to user // For now just clear the request from the pending list @@ -780,12 +780,12 @@ public: } } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { llwarns << "Transport error requesting object physics flags " - << "HTTP status: " << statusNum << ", reason: " - << reason << "." << llendl; + << "[status: " << statusNum << "]: " + << content << llendl; // TODO*: Error message to user // For now just clear the request from the pending list diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index e940dda010..b8b53aa6e4 100755 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -210,9 +210,9 @@ public: virtual ~BaseCapabilitiesComplete() { } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - LL_WARNS2("AppInit", "Capabilities") << statusNum << ": " << reason << LL_ENDL; + LL_WARNS2("AppInit", "Capabilities") << "[status:" << statusNum << ":] " << content << LL_ENDL; LLViewerRegion *regionp = LLWorld::getInstance()->getRegionFromHandle(mRegionHandle); if (regionp) { @@ -278,8 +278,11 @@ public: virtual ~BaseCapabilitiesCompleteTracker() { } - void error(U32 statusNum, const std::string& reason) - { } + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) + { + llwarns << "BaseCapabilitiesCompleteTracker error [status:" + << statusNum << "]: " << content << llendl; + } void result(const LLSD& content) { @@ -1731,9 +1734,9 @@ public: { } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - LL_WARNS2("AppInit", "SimulatorFeatures") << statusNum << ": " << reason << LL_ENDL; + LL_WARNS2("AppInit", "SimulatorFeatures") << "[status:" << statusNum << "]: " << content << LL_ENDL; retry(); } diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index 17bb03b889..4ed01f36ab 100755 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -530,10 +530,10 @@ class ViewerStatsResponder : public LLHTTPClient::Responder public: ViewerStatsResponder() { } - void error(U32 statusNum, const std::string& reason) + void errorWithContent(U32 statusNum, const std::string& reason, const LLSD& content) { - llinfos << "ViewerStatsResponder::error " << statusNum << " " - << reason << llendl; + llwarns << "ViewerStatsResponder error [status:" << statusNum << "]: " + << content << llendl; } void result(const LLSD& content) diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp index 3605383c5c..9be1de4f0e 100755 --- a/indra/newview/llvoavatarself.cpp +++ b/indra/newview/llvoavatarself.cpp @@ -2264,7 +2264,7 @@ public: else { LL_WARNS("Avatar") << "Failed " << status << " reason " << reason << LL_ENDL; - error(status,reason); + errorWithContent(status,reason,content); } } @@ -2440,11 +2440,12 @@ public: } // Error - /*virtual*/ void error(U32 status, const std::string& reason) + /*virtual*/ void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { if (isAgentAvatarValid()) { - LL_DEBUGS("Avatar") << "failed, will rebake" << llendl; + LL_DEBUGS("Avatar") << "failed, will rebake [status:" + << status << "]: " << content << llendl; forceAppearanceUpdate(); } } diff --git a/indra/newview/llvoicechannel.cpp b/indra/newview/llvoicechannel.cpp index bd12328a6b..181735ee30 100644 --- a/indra/newview/llvoicechannel.cpp +++ b/indra/newview/llvoicechannel.cpp @@ -56,7 +56,8 @@ class LLVoiceCallCapResponder : public LLHTTPClient::Responder public: LLVoiceCallCapResponder(const LLUUID& session_id) : mSessionID(session_id) {}; - virtual void error(U32 status, const std::string& reason); // called with bad status codes + // called with bad status codes + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); virtual void result(const LLSD& content); private: @@ -64,11 +65,10 @@ private: }; -void LLVoiceCallCapResponder::error(U32 status, const std::string& reason) +void LLVoiceCallCapResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("Voice") << "LLVoiceCallCapResponder::error(" - << status << ": " << reason << ")" - << LL_ENDL; + LL_WARNS("Voice") << "LLVoiceCallCapResponder error [status:" + << status << "]: " << content << LL_ENDL; LLVoiceChannel* channelp = LLVoiceChannel::getChannelByID(mSessionID); if ( channelp ) { diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp index db0fc3dca7..e112c589e9 100644 --- a/indra/newview/llvoicevivox.cpp +++ b/indra/newview/llvoicevivox.cpp @@ -126,17 +126,18 @@ public: mRetries = retries; } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { + LL_WARNS("Voice") << "ProvisionVoiceAccountRequest returned an error, " + << ( (mRetries > 0) ? "retrying" : "too many retries (giving up)" ) + << status << "]: " << content << LL_ENDL; + if ( mRetries > 0 ) { - LL_WARNS("Voice") << "ProvisionVoiceAccountRequest returned an error, retrying. status = " << status << ", reason = \"" << reason << "\"" << LL_ENDL; - LLVivoxVoiceClient::getInstance()->requestVoiceAccountProvision( - mRetries - 1); + LLVivoxVoiceClient::getInstance()->requestVoiceAccountProvision(mRetries - 1); } else { - LL_WARNS("Voice") << "ProvisionVoiceAccountRequest returned an error, too many retries (giving up). status = " << status << ", reason = \"" << reason << "\"" << LL_ENDL; LLVivoxVoiceClient::getInstance()->giveUp(); } } @@ -195,18 +196,18 @@ class LLVivoxVoiceClientCapResponder : public LLHTTPClient::Responder public: LLVivoxVoiceClientCapResponder(LLVivoxVoiceClient::state requesting_state) : mRequestingState(requesting_state) {}; - virtual void error(U32 status, const std::string& reason); // called with bad status codes + // called with bad status codes + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); virtual void result(const LLSD& content); private: LLVivoxVoiceClient::state mRequestingState; // state }; -void LLVivoxVoiceClientCapResponder::error(U32 status, const std::string& reason) +void LLVivoxVoiceClientCapResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("Voice") << "LLVivoxVoiceClientCapResponder::error(" - << status << ": " << reason << ")" - << LL_ENDL; + LL_WARNS("Voice") << "LLVivoxVoiceClientCapResponder error [status:" + << status << "]: " << content << LL_ENDL; LLVivoxVoiceClient::getInstance()->sessionTerminate(); } diff --git a/indra/newview/llwebsharing.cpp b/indra/newview/llwebsharing.cpp index 43b1a320c3..3a80051b9b 100644 --- a/indra/newview/llwebsharing.cpp +++ b/indra/newview/llwebsharing.cpp @@ -68,9 +68,9 @@ public: } } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("WebSharing") << "Error [" << status << "]: " << reason << LL_ENDL; + LL_WARNS("WebSharing") << "Error [status:" << status << "]: " << content << LL_ENDL; } virtual void result(const LLSD& content) @@ -99,7 +99,7 @@ public: /// Left empty to override the default LLSD parsing behaviour. } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { if (HTTP_UNAUTHORIZED == status) { @@ -108,7 +108,7 @@ public: } else { - LL_WARNS("WebSharing") << "Error [" << status << "]: " << reason << LL_ENDL; + LL_WARNS("WebSharing") << "Error [status:" << status << "]: " << content << LL_ENDL; LLWebSharing::instance().retryOpenIDAuth(); } @@ -152,9 +152,9 @@ public: } } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("WebSharing") << "Error [" << status << "]: " << reason << LL_ENDL; + LL_WARNS("WebSharing") << "Error [status:" << status << "]: " << content << LL_ENDL; LLWebSharing::instance().retryOpenIDAuth(); } @@ -221,9 +221,9 @@ public: } } - virtual void error(U32 status, const std::string& reason) + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_WARNS("WebSharing") << "Error [" << status << "]: " << reason << LL_ENDL; + LL_WARNS("WebSharing") << "Error [status:" << status << "]: " << content << LL_ENDL; } virtual void result(const LLSD& content) diff --git a/indra/newview/llwlhandlers.cpp b/indra/newview/llwlhandlers.cpp index be3e3ff30e..93eba5b604 100644 --- a/indra/newview/llwlhandlers.cpp +++ b/indra/newview/llwlhandlers.cpp @@ -121,9 +121,11 @@ LLEnvironmentRequestResponder::LLEnvironmentRequestResponder() LLEnvManagerNew::getInstance()->onRegionSettingsResponse(unvalidated_content); } -/*virtual*/ void LLEnvironmentRequestResponder::error(U32 status, const std::string& reason) +/*virtual*/ +void LLEnvironmentRequestResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - LL_INFOS("WindlightCaps") << "Got an error, not using region windlight..." << LL_ENDL; + LL_INFOS("WindlightCaps") << "Got an error, not using region windlight... [status:" + << status << "]: " << content << LL_ENDL; LLEnvManagerNew::getInstance()->onRegionSettingsResponse(LLSD()); } @@ -190,14 +192,15 @@ bool LLEnvironmentApply::initiateRequest(const LLSD& content) LLEnvManagerNew::instance().onRegionSettingsApplyResponse(false); } } -/*virtual*/ void LLEnvironmentApplyResponder::error(U32 status, const std::string& reason) +/*virtual*/ +void LLEnvironmentApplyResponder::errorWithContent(U32 status, const std::string& reason, const LLSD& content) { - std::stringstream msg; - msg << reason << " (Code " << status << ")"; - - LL_WARNS("WindlightCaps") << "Couldn't apply windlight settings to region! Reason: " << msg << LL_ENDL; + LL_WARNS("WindlightCaps") << "Couldn't apply windlight settings to region! [status:" + << status << "]: " << content << LL_ENDL; LLSD args(LLSD::emptyMap()); + std::stringstream msg; + msg << reason << " (Code " << status << ")"; args["FAIL_REASON"] = msg.str(); LLNotificationsUtil::add("WLRegionApplyFail", args); } diff --git a/indra/newview/llwlhandlers.h b/indra/newview/llwlhandlers.h index 23558876da..598ce6d52a 100644 --- a/indra/newview/llwlhandlers.h +++ b/indra/newview/llwlhandlers.h @@ -47,7 +47,7 @@ class LLEnvironmentRequestResponder: public LLHTTPClient::Responder LOG_CLASS(LLEnvironmentRequestResponder); public: virtual void result(const LLSD& content); - virtual void error(U32 status, const std::string& reason); + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); private: friend class LLEnvironmentRequest; @@ -89,7 +89,8 @@ public: */ virtual void result(const LLSD& content); - virtual void error(U32 status, const std::string& reason); // non-200 errors only + // non-200 errors only + virtual void errorWithContent(U32 status, const std::string& reason, const LLSD& content); private: friend class LLEnvironmentApply; diff --git a/indra/newview/tests/llmediadataclient_test.cpp b/indra/newview/tests/llmediadataclient_test.cpp index 0254c5881f..41cb344808 100644 --- a/indra/newview/tests/llmediadataclient_test.cpp +++ b/indra/newview/tests/llmediadataclient_test.cpp @@ -126,7 +126,9 @@ void LLHTTPClient::post( result[LLTextureEntry::OBJECT_ID_KEY] = body[LLTextureEntry::OBJECT_ID_KEY]; if ( url == FAKE_OBJECT_MEDIA_CAP_URL_503 ) { - responder->error(HTTP_SERVICE_UNAVAILABLE, "fake reason"); + LLSD content; + content["reason"] = "fake reason"; + responder->errorWithContent(HTTP_SERVICE_UNAVAILABLE, "fake reason", content); return; } else if (url == FAKE_OBJECT_MEDIA_NAVIGATE_CAP_URL_ERROR) |