Added reset curl handle when returning to handle pool

This commit is contained in:
Takeshi Nakatani 2018-05-06 12:11:53 +00:00
parent 1db4739ed8
commit e3de6ea458

View File

@ -304,6 +304,7 @@ void CurlHandlerPool::ReturnHandler(CURL* h)
pthread_mutex_lock(&mLock);
if (mIndex < mMaxHandlers - 1) {
mHandlers[++mIndex] = h;
curl_easy_reset(h);
needCleanup = false;
S3FS_PRN_DBG("Return handler to pool: %d", mIndex);
}