summaryrefslogtreecommitdiff
path: root/ext/curl/curl.c
diff options
context:
space:
mode:
authorKristian Köhntopp <kk@php.net>2000-07-25 22:15:26 +0000
committerKristian Köhntopp <kk@php.net>2000-07-25 22:15:26 +0000
commit19687ea1ed0fd31168c7097ea9b1a69b095ccc27 (patch)
treec76b11018cbff5076124e5ad3c57e3adf87d4519 /ext/curl/curl.c
parentb3305dab642684fee25ae04860e2650e13ecb1c1 (diff)
downloadphp-git-19687ea1ed0fd31168c7097ea9b1a69b095ccc27.tar.gz
Trivial change to add access to CURL version information for
user programs in order to have them react appropriately.
Diffstat (limited to 'ext/curl/curl.c')
-rw-r--r--ext/curl/curl.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/ext/curl/curl.c b/ext/curl/curl.c
index a29a9f07fc..4c8af7a481 100644
--- a/ext/curl/curl.c
+++ b/ext/curl/curl.c
@@ -37,6 +37,7 @@ php_curl_globals curl_globals;
function_entry curl_functions[] = {
PHP_FE (curl_init, NULL)
+ PHP_FE (curl_version, NULL)
PHP_FE (curl_setopt, NULL)
PHP_FE (curl_exec, NULL)
PHP_FE (curl_close, NULL)
@@ -122,6 +123,14 @@ PHP_MINIT_FUNCTION(curl)
return SUCCESS;
}
+/* {{{ proto string curl_version ()
+ Return the CURL version string. */
+PHP_FUNCTION (curl_version)
+{
+ RETURN_STRING(curl_version(),1);
+}
+/* }}} */
+
/* {{{ proto int curl_init ([string url])
Initialize a CURL session */
PHP_FUNCTION (curl_init)
@@ -260,4 +269,4 @@ PHP_FUNCTION (curl_close)
}
/* }}} */
-#endif \ No newline at end of file
+#endif