summaryrefslogtreecommitdiff
path: root/indra/newview/llxmlrpclistener.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llxmlrpclistener.cpp')
-rw-r--r--indra/newview/llxmlrpclistener.cpp68
1 files changed, 34 insertions, 34 deletions
diff --git a/indra/newview/llxmlrpclistener.cpp b/indra/newview/llxmlrpclistener.cpp
index 3c2c6d15c4..0eabb8983e 100644
--- a/indra/newview/llxmlrpclistener.cpp
+++ b/indra/newview/llxmlrpclistener.cpp
@@ -3,25 +3,25 @@
* @author Nat Goodspeed
* @date 2009-03-18
* @brief Implementation for llxmlrpclistener.
- *
+ *
* $LicenseInfo:firstyear=2009&license=viewerlgpl$
* Second Life Viewer Source Code
* Copyright (C) 2010, Linden Research, Inc.
- *
+ *
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
- *
+ *
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
- *
+ *
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
+ *
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
@@ -88,13 +88,13 @@ class StatusMapper: public StatusMapperBase<LLXMLRPCTransaction::EStatus>
public:
StatusMapper(): StatusMapperBase<LLXMLRPCTransaction::EStatus>("Status")
{
- mMap[LLXMLRPCTransaction::StatusNotStarted] = "NotStarted";
- mMap[LLXMLRPCTransaction::StatusStarted] = "Started";
- mMap[LLXMLRPCTransaction::StatusDownloading] = "Downloading";
- mMap[LLXMLRPCTransaction::StatusComplete] = "Complete";
- mMap[LLXMLRPCTransaction::StatusCURLError] = "CURLError";
- mMap[LLXMLRPCTransaction::StatusXMLRPCError] = "XMLRPCError";
- mMap[LLXMLRPCTransaction::StatusOtherError] = "OtherError";
+ mMap[LLXMLRPCTransaction::StatusNotStarted] = "NotStarted";
+ mMap[LLXMLRPCTransaction::StatusStarted] = "Started";
+ mMap[LLXMLRPCTransaction::StatusDownloading] = "Downloading";
+ mMap[LLXMLRPCTransaction::StatusComplete] = "Complete";
+ mMap[LLXMLRPCTransaction::StatusCURLError] = "CURLError";
+ mMap[LLXMLRPCTransaction::StatusXMLRPCError] = "XMLRPCError";
+ mMap[LLXMLRPCTransaction::StatusOtherError] = "OtherError";
}
};
@@ -285,7 +285,7 @@ public:
XMLRPC_RequestSetData(request, xparams);
mTransaction.reset(new LLXMLRPCTransaction(mUri, request, true, command.has("http_params")? LLSD(command["http_params"]) : LLSD()));
- mPreviousStatus = mTransaction->status(NULL);
+ mPreviousStatus = mTransaction->status(NULL);
// Free the XMLRPC_REQUEST object and the attached data values.
XMLRPC_RequestFree(request, 1);
@@ -323,42 +323,42 @@ public:
data["error"] = "";
data["transfer_rate"] = 0.0;
LLEventPump& replyPump(LLEventPumps::instance().obtain(mReplyPump));
- if (! done)
+ if (! done)
{
// Not done yet, carry on.
- if (status == LLXMLRPCTransaction::StatusDownloading
- && status != mPreviousStatus)
- {
- // If a response has been received, send the
- // 'downloading' status if it hasn't been sent.
- replyPump.post(data);
- }
-
- mPreviousStatus = status;
+ if (status == LLXMLRPCTransaction::StatusDownloading
+ && status != mPreviousStatus)
+ {
+ // If a response has been received, send the
+ // 'downloading' status if it hasn't been sent.
+ replyPump.post(data);
+ }
+
+ mPreviousStatus = status;
return false;
}
// Here the transaction is complete. Check status.
data["error"] = mTransaction->statusMessage();
- data["transfer_rate"] = mTransaction->transferRate();
+ data["transfer_rate"] = mTransaction->transferRate();
LL_INFOS("LLXMLRPCListener") << mMethod << " result from " << mUri << ": status "
<< data["status"].asString() << ", errorcode "
<< data["errorcode"].asString()
<< " (" << data["error"].asString() << ")"
<< LL_ENDL;
-
- switch (curlcode)
- {
+
+ switch (curlcode)
+ {
#if CURLE_SSL_PEER_CERTIFICATE != CURLE_SSL_CACERT
- case CURLE_SSL_PEER_CERTIFICATE:
+ case CURLE_SSL_PEER_CERTIFICATE:
#endif
- case CURLE_SSL_CACERT:
+ case CURLE_SSL_CACERT:
data["certificate"] = mTransaction->getErrorCertData();
- break;
+ break;
- default:
- break;
- }
+ default:
+ break;
+ }
// values of 'curlcode':
// CURLE_COULDNT_RESOLVE_HOST,
// CURLE_SSL_PEER_CERTIFICATE,
@@ -545,7 +545,7 @@ private:
const std::string mReplyPump;
LLTempBoundListener mBoundListener;
std::unique_ptr<LLXMLRPCTransaction> mTransaction;
- LLXMLRPCTransaction::EStatus mPreviousStatus; // To detect state changes.
+ LLXMLRPCTransaction::EStatus mPreviousStatus; // To detect state changes.
};
bool LLXMLRPCListener::process(const LLSD& command)