mirror of
https://github.com/s3fs-fuse/s3fs-fuse.git
synced 2024-12-23 01:08:54 +00:00
fix: miss header when retry
This commit is contained in:
parent
a16d00d673
commit
51f65d7b14
13
src/curl.cpp
13
src/curl.cpp
@ -2230,16 +2230,17 @@ int S3fsCurl::RequestPerform(bool dontAddAuthHeaders /*=false*/)
|
||||
long responseCode;
|
||||
int result = S3FSCURL_PERFORM_RESULT_NOTSET;
|
||||
|
||||
if(!dontAddAuthHeaders) {
|
||||
insertAuthHeaders();
|
||||
}
|
||||
|
||||
curl_easy_setopt(hCurl, CURLOPT_HTTPHEADER, requestHeaders);
|
||||
|
||||
// 1 attempt + retries...
|
||||
for(int retrycnt = 0; S3FSCURL_PERFORM_RESULT_NOTSET == result && retrycnt < S3fsCurl::retries; ++retrycnt){
|
||||
// Reset response code
|
||||
responseCode = S3FSCURL_RESPONSECODE_NOTSET;
|
||||
|
||||
// Insert headers
|
||||
if(!dontAddAuthHeaders) {
|
||||
insertAuthHeaders();
|
||||
}
|
||||
|
||||
curl_easy_setopt(hCurl, CURLOPT_HTTPHEADER, requestHeaders);
|
||||
|
||||
// Requests
|
||||
CURLcode curlCode = curl_easy_perform(hCurl);
|
||||
|
Loading…
Reference in New Issue
Block a user