]> granicus.if.org Git - php/commitdiff
Add CURL_WRAPPERS_ENABLE constant
authorXinchen Hui <laruence@php.net>
Wed, 3 Apr 2013 02:09:51 +0000 (10:09 +0800)
committerXinchen Hui <laruence@php.net>
Wed, 3 Apr 2013 02:09:51 +0000 (10:09 +0800)
see http://news.php.net/php.internals/66871

NEWS
ext/curl/interface.c

diff --git a/NEWS b/NEWS
index ad4852d4b513b473a989420f1380ea87e1a87d4b..f250afa093f212910193cb9c42d80ae1a0e0003f 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,9 @@ PHP                                                                        NEWS
   . Fixed bug #64433 (follow_location parameter of context is ignored for most 
     response codes). (Sergey Akbarov)
 
+- CURL
+  . Add CURL_WRAPPERS_ENABLE constant. (Laruence)
+
 ?? ??? 2013, PHP 5.4.14
 - Core:
   . Fixed bug #64529 (Ran out of opcode space). (Dmitry)
index 531f15ba15f812ad2e73e0ba061e468df7a9b8a2..ee205a707bbb026c4d66dd1d56692dcad974aea7 100644 (file)
@@ -914,6 +914,7 @@ PHP_MINIT_FUNCTION(curl)
        }
 
 #ifdef PHP_CURL_URL_WRAPPERS
+       REGISTER_LONG_CONSTANT("CURL_WRAPPERS_ENABLE", 1, CONST_CS | CONST_PERSISTENT);
 # if HAVE_CURL_VERSION_INFO
        {
                curl_version_info_data *info = curl_version_info(CURLVERSION_NOW);
@@ -940,6 +941,8 @@ PHP_MINIT_FUNCTION(curl)
        php_unregister_url_stream_wrapper("ldap");
        php_register_url_stream_wrapper("ldap", &php_curl_wrapper TSRMLS_CC);
 # endif
+#else
+       REGISTER_LONG_CONSTANT("CURL_WRAPPERS_ENABLE", 0, CONST_CS | CONST_PERSISTENT);
 #endif
 
        return SUCCESS;