summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterabout.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloaterabout.cpp')
-rwxr-xr-xindra/newview/llfloaterabout.cpp39
1 files changed, 14 insertions, 25 deletions
diff --git a/indra/newview/llfloaterabout.cpp b/indra/newview/llfloaterabout.cpp
index 83fb887d81..801a24f472 100755
--- a/indra/newview/llfloaterabout.cpp
+++ b/indra/newview/llfloaterabout.cpp
@@ -77,14 +77,9 @@ class LLServerReleaseNotesURLFetcher : public LLHTTPClient::Responder
{
LOG_CLASS(LLServerReleaseNotesURLFetcher);
public:
-
static void startFetch();
- /*virtual*/ void completedHeader(U32 status, const std::string& reason, const LLSD& content);
- /*virtual*/ void completedRaw(
- U32 status,
- const std::string& reason,
- const LLChannelDescriptors& channels,
- const LLIOPipe::buffer_ptr_t& buffer);
+private:
+ /* virtual */ void httpCompleted();
};
///----------------------------------------------------------------------------
@@ -471,32 +466,26 @@ void LLServerReleaseNotesURLFetcher::startFetch()
}
// virtual
-void LLServerReleaseNotesURLFetcher::completedHeader(U32 status, const std::string& reason, const LLSD& content)
+void LLServerReleaseNotesURLFetcher::httpCompleted()
{
- lldebugs << "Status: " << status << llendl;
- lldebugs << "Reason: " << reason << llendl;
- lldebugs << "Headers: " << content << llendl;
+ LL_DEBUGS("ServerReleaseNotes") << dumpResponse()
+ << " [headers:" << getResponseHeaders() << "]" << LL_ENDL;
LLFloaterAbout* floater_about = LLFloaterReg::getTypedInstance<LLFloaterAbout>("sl_about");
if (floater_about)
{
- std::string location = content["location"].asString();
+ const std::string& location = getResponseHeader(HTTP_IN_HEADER_LOCATION);
if (location.empty())
{
- location = floater_about->getString("ErrorFetchingServerReleaseNotesURL");
+ LL_WARNS("ServerReleaseNotes") << "Missing Location header "
+ << dumpResponse() << " [headers:" << getResponseHeaders() << "]" << LL_ENDL;
+ floater_about->updateServerReleaseNotesURL(
+ floater_about->getString("ErrorFetchingServerReleaseNotesURL"));
+ }
+ else
+ {
+ floater_about->updateServerReleaseNotesURL(location);
}
- floater_about->updateServerReleaseNotesURL(location);
}
}
-// virtual
-void LLServerReleaseNotesURLFetcher::completedRaw(
- U32 status,
- const std::string& reason,
- const LLChannelDescriptors& channels,
- const LLIOPipe::buffer_ptr_t& buffer)
-{
- // Do nothing.
- // We're overriding just because the base implementation tries to
- // deserialize LLSD which triggers warnings.
-}