Skip to content
Snippets Groups Projects
Commit 94ad019c authored by Xiaohong Bao's avatar Xiaohong Bao
Browse files

fix for SH-2823 and SH-2824: crash in curl: LLBufferArray::countAfter() and...

fix for SH-2823 and SH-2824: crash in curl: LLBufferArray::countAfter() and LLBufferArray::copyIntoBuffers
reviewed by vir
parent 7fe5cbc5
No related branches found
No related tags found
No related merge requests found
...@@ -64,7 +64,7 @@ class LLURLRequestDetail ...@@ -64,7 +64,7 @@ class LLURLRequestDetail
~LLURLRequestDetail(); ~LLURLRequestDetail();
std::string mURL; std::string mURL;
LLCurlEasyRequest* mCurlRequest; LLCurlEasyRequest* mCurlRequest;
LLBufferArray* mResponseBuffer; LLIOPipe::buffer_ptr_t mResponseBuffer;
LLChannelDescriptors mChannels; LLChannelDescriptors mChannels;
U8* mLastRead; U8* mLastRead;
U32 mBodyLimit; U32 mBodyLimit;
...@@ -75,7 +75,6 @@ class LLURLRequestDetail ...@@ -75,7 +75,6 @@ class LLURLRequestDetail
LLURLRequestDetail::LLURLRequestDetail() : LLURLRequestDetail::LLURLRequestDetail() :
mCurlRequest(NULL), mCurlRequest(NULL),
mResponseBuffer(NULL),
mLastRead(NULL), mLastRead(NULL),
mBodyLimit(0), mBodyLimit(0),
mByteAccumulator(0), mByteAccumulator(0),
...@@ -90,7 +89,6 @@ LLURLRequestDetail::~LLURLRequestDetail() ...@@ -90,7 +89,6 @@ LLURLRequestDetail::~LLURLRequestDetail()
{ {
LLMemType m1(LLMemType::MTYPE_IO_URL_REQUEST); LLMemType m1(LLMemType::MTYPE_IO_URL_REQUEST);
delete mCurlRequest; delete mCurlRequest;
mResponseBuffer = NULL;
mLastRead = NULL; mLastRead = NULL;
} }
...@@ -326,7 +324,7 @@ LLIOPipe::EStatus LLURLRequest::process_impl( ...@@ -326,7 +324,7 @@ LLIOPipe::EStatus LLURLRequest::process_impl(
// *FIX: bit of a hack, but it should work. The configure and // *FIX: bit of a hack, but it should work. The configure and
// callback method expect this information to be ready. // callback method expect this information to be ready.
mDetail->mResponseBuffer = buffer.get(); mDetail->mResponseBuffer = buffer;
mDetail->mChannels = channels; mDetail->mChannels = channels;
if(!configure()) if(!configure())
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment