File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -541,6 +541,11 @@ std::shared_ptr<HttpResponse> CurlHttpClient::makeRequest(const std::shared_ptr<
541541 curl_easy_setopt (curl, CURLOPT_DEBUGFUNCTION, debugCallback);
542542 }
543543
544+ // Error Buffer
545+ char errbuf[CURL_ERROR_SIZE];
546+ curl_easy_setopt (curl, CURLOPT_ERRORBUFFER, errbuf);
547+ errbuf[0 ] = 0 ;
548+
544549 // progress Callback
545550 curl_easy_setopt (curl, CURLOPT_PROGRESSFUNCTION, progressCallback);
546551 curl_easy_setopt (curl, CURLOPT_PROGRESSDATA, &transferState);
@@ -587,7 +592,11 @@ std::shared_ptr<HttpResponse> CurlHttpClient::makeRequest(const std::shared_ptr<
587592 }
588593 break ;
589594 default :
590- response->setStatusMsg (curl_easy_strerror (res));
595+ {
596+ std::string msg (curl_easy_strerror (res));
597+ msg.append (" ." ).append (errbuf);
598+ response->setStatusMsg (msg);
599+ }
591600 break ;
592601 };
593602 }
You can’t perform that action at this time.
0 commit comments