From: Daniel Stenberg Date: Sat, 31 Aug 2024 15:24:01 +0000 (+0200) Subject: curl.h: make CURLOPT_WRITEINFO and CURLOPT_CLOSEPOLICY compile X-Git-Tag: curl-8_10_0~63 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8bb71d5fd371cf2b7ce16d5a124304a4d0d4fc0d;p=thirdparty%2Fcurl.git curl.h: make CURLOPT_WRITEINFO and CURLOPT_CLOSEPOLICY compile The symbols have not been in use for 17+ years and they did not do anything for several years before that, but apparently there are still code using them. Follow-up to 3b057d4b7a7 Fixes #14747 Reported-by: Kai Pastor Closes #14748 --- diff --git a/include/curl/curl.h b/include/curl/curl.h index 1609ff6cf2..dae533e32d 100644 --- a/include/curl/curl.h +++ b/include/curl/curl.h @@ -721,6 +721,8 @@ typedef enum { with them. */ #define CURLOPT_WRITEINFO CURLOPT_OBSOLETE40 #define CURLOPT_CLOSEPOLICY CURLOPT_OBSOLETE72 +#define CURLOPT_OBSOLETE72 9999 +#define CURLOPT_OBSOLETE40 9999 #endif /* !CURL_NO_OLDIES */ diff --git a/lib/optiontable.pl b/lib/optiontable.pl index 511322a347..2727784e7b 100755 --- a/lib/optiontable.pl +++ b/lib/optiontable.pl @@ -105,7 +105,7 @@ while() { if(/^#define (CURLOPT_[^ ]*) *(CURLOPT_\S*)/) { my ($o, $n)=($1, $2); # skip obsolete ones - if($n !~ /OBSOLETE/) { + if(($n !~ /OBSOLETE/) && ($o !~ /OBSOLETE/)) { $o =~ s/^CURLOPT_//; $n =~ s/^CURLOPT_//; $alias{$o} = $n;