summaryrefslogtreecommitdiff
path: root/indra/newview/llxmlrpctransaction.cpp
diff options
context:
space:
mode:
authorDebi King (Dessie) <dessie@lindenlab.com>2012-01-30 22:27:01 -0500
committerDebi King (Dessie) <dessie@lindenlab.com>2012-01-30 22:27:01 -0500
commita39937f9303ce2100ebb40d6fcaa8d36a14e3cb7 (patch)
tree3c0d951cafadbd90c736cfbb9e2e4329d05407c7 /indra/newview/llxmlrpctransaction.cpp
parent6298daf266369dbd3600c5fdf287f9c680b2a897 (diff)
parentbd4c629e38aa2ab7223a5ef3b8e23ad91229b512 (diff)
merge
Diffstat (limited to 'indra/newview/llxmlrpctransaction.cpp')
-rw-r--r--indra/newview/llxmlrpctransaction.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/newview/llxmlrpctransaction.cpp b/indra/newview/llxmlrpctransaction.cpp
index 920a9a3752..0da70d398b 100644
--- a/indra/newview/llxmlrpctransaction.cpp
+++ b/indra/newview/llxmlrpctransaction.cpp
@@ -305,6 +305,15 @@ void LLXMLRPCTransaction::Impl::init(XMLRPC_REQUEST request, bool useGzip)
{
mCurlRequest = new LLCurlEasyRequest();
}
+ if(!mCurlRequest->isValid())
+ {
+ llwarns << "mCurlRequest is invalid." << llendl ;
+
+ delete mCurlRequest ;
+ mCurlRequest = NULL ;
+ return ;
+ }
+
mErrorCert = NULL;
// mCurlRequest->setopt(CURLOPT_VERBOSE, 1); // useful for debugging
@@ -357,10 +366,20 @@ LLXMLRPCTransaction::Impl::~Impl()
}
delete mCurlRequest;
+ mCurlRequest = NULL ;
}
bool LLXMLRPCTransaction::Impl::process()
{
+ if(!mCurlRequest || !mCurlRequest->isValid())
+ {
+ llwarns << "transaction failed." << llendl ;
+
+ delete mCurlRequest ;
+ mCurlRequest = NULL ;
+ return true ; //failed, quit.
+ }
+
switch(mStatus)
{
case LLXMLRPCTransaction::StatusComplete: