X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=scripts%2Fgen_curlinfo.php;h=54137ba2c9e3b528aa1f1a5b09d8fe0b59a22cb1;hp=f7c6cdb53d55ad0dfc5f3b124256495c1cb57fbc;hb=c52642ccff4fe2887c9d5581816a7cae55766df4;hpb=d982551f5260407a6301c662604ac0b854fb7ba0 diff --git a/scripts/gen_curlinfo.php b/scripts/gen_curlinfo.php index f7c6cdb..54137ba 100644 --- a/scripts/gen_curlinfo.php +++ b/scripts/gen_curlinfo.php @@ -32,7 +32,11 @@ function file_re($file, $pattern, $all = true) { } $ifdefs = array( - 'COOKIELIST' => '7,14,1' + 'COOKIELIST' => 'HTTP_CURL_VERSION(7,14,1)', + 'PRIMARY_IP' => 'HTTP_CURL_VERSION(7,19,0)', + 'APPCONNECT_TIME' => 'HTTP_CURL_VERSION(7,19,0)', + 'REDIRECT_URL' => 'HTTP_CURL_VERSION(7,18,2)', + 'CERTINFO' => 'HTTP_CURL_VERSION(7,19,1) && defined(HTTP_HAVE_OPENSSL)' ); $exclude = array( 'PRIVATE', 'LASTSOCKET', 'FTP_ENTRY_PATH' @@ -77,7 +81,7 @@ ob_start(); foreach ($infos as $info) { list(, $full, $short, $type) = $info; if (in_array($short, $exclude)) continue; - if (isset($ifdefs[$short])) printf("#if HTTP_CURL_VERSION(%s)\n", $ifdefs[$short]); + if (isset($ifdefs[$short])) printf("#if %s\n", $ifdefs[$short]); printf($templates[$type], $full, strtolower((isset($translate[$short])) ? $translate[$short] : $short)); if (isset($ifdefs[$short])) printf("#endif\n"); }