Skip to content

Commit 11d12f1

Browse files
committed
Version guard use of struct curl_blob to curl 7.71.0 and greater, closes #194
1 parent 5b57e0e commit 11d12f1

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

http.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -910,6 +910,7 @@ set_curlopt(CURL* handle, const http_curlopt *opt)
910910
err = curl_easy_setopt(handle, opt->curlopt, value_long);
911911
elog(DEBUG2, "pgsql-http: set '%s' to value '%ld', return value = %d", opt->curlopt_guc, value_long, err);
912912
}
913+
#if LIBCURL_VERSION_NUM >= 0x074700 /* 7.71.0 */
913914
/* Only used for CURLOPT_SSLKEY_BLOB and CURLOPT_SSLCERT_BLOB */
914915
else if (opt->curlopt_type == CURLOPT_BLOB)
915916
{
@@ -924,6 +925,7 @@ set_curlopt(CURL* handle, const http_curlopt *opt)
924925
err = curl_easy_setopt(handle, opt->curlopt, &blob);
925926
elog(DEBUG2, "pgsql-http: set '%s' to value '%s', return value = %d", opt->curlopt_guc, opt->curlopt_val, err);
926927
}
928+
#endif
927929
else
928930
{
929931
/* Never get here */

0 commit comments

Comments
 (0)