Fine tune of private (libcwd) assertion.
It turns out that it's possible to receive data before an upload finished when the server sends HTTP_BAD_REQUEST in the middle of the upload (this happens to me when I try to upload a 6000x6000 image to my profile feed, with is a 44MB file). So, in that case the finished upload detection did not fail and we shouldn't assert.
This commit is contained in:
@@ -1276,7 +1276,7 @@ static int const HTTP_REDIRECTS_DEFAULT = 10;
|
||||
|
||||
LLChannelDescriptors const BufferedCurlEasyRequest::sChannels;
|
||||
|
||||
BufferedCurlEasyRequest::BufferedCurlEasyRequest() : mRequestTransferedBytes(0), mResponseTransferedBytes(0), mBufferEventsTarget(NULL)
|
||||
BufferedCurlEasyRequest::BufferedCurlEasyRequest() : mRequestTransferedBytes(0), mResponseTransferedBytes(0), mBufferEventsTarget(NULL), mStatus(HTTP_INTERNAL_ERROR)
|
||||
{
|
||||
AICurlInterface::Stats::BufferedCurlEasyRequest_count++;
|
||||
}
|
||||
@@ -1336,8 +1336,13 @@ void BufferedCurlEasyRequest::resetState(void)
|
||||
// Call base class implementation.
|
||||
CurlEasyRequest::resetState();
|
||||
|
||||
// Reset local variables.
|
||||
mOutput.reset();
|
||||
mInput.reset();
|
||||
mRequestTransferedBytes = 0;
|
||||
mResponseTransferedBytes = 0;
|
||||
mBufferEventsTarget = NULL;
|
||||
mStatus = HTTP_INTERNAL_ERROR;
|
||||
}
|
||||
|
||||
void BufferedCurlEasyRequest::print_diagnostics(CURLcode code)
|
||||
|
||||
Reference in New Issue
Block a user