Merge branch 'v2.6.x'
authorMichael Wallner <mike@php.net>
Wed, 7 Sep 2016 06:01:09 +0000 (08:01 +0200)
committerMichael Wallner <mike@php.net>
Wed, 7 Sep 2016 06:02:46 +0000 (08:02 +0200)
1  2 
package.xml
scripts/gen_travis_yml.php
src/php_http_client.c
src/php_http_client_curl_user.c
tests/client028.phpt
tests/client029.phpt
tests/gh-issue47.phpt
tests/gh-issue50.phpt

diff --cc package.xml
index e104c7ebfc599fbd073a995a959a13849331cc85,0e2206660d33b672e59773cc1f375b5293d7956d..f8d65e0aaf08718262b9baf0bcdd4aea31027c5a
@@@ -31,10 -31,10 +31,10 @@@ https://mdref.m6w6.name/htt
    <email>mike@php.net</email>
    <active>yes</active>
   </lead>
-  <date>2016-08-22</date>
+  <date>2016-09-07</date>
   <version>
 -  <release>2.6.0beta2</release>
 -  <api>2.6.0</api>
 +  <release>3.1.0beta2</release>
 +  <api>3.1.0</api>
   </version>
   <stability>
    <release>beta</release>
  * Fix gh-issue #36: Unexpected cookies sent if persistent_handle_id is used (Mike, @rcanavan, @afflerbach)
  * Fix gh-issue #34: allow setting multiple headers with the same name (Mike, @rcanavan)
  * Fix gh-issue #33: allow setting prodyhost request option to NULL (Mike, @rcanavan)
 -* Fix gh-issue #31: add/improve configure checks for default CA bundle/path (Mike, @rcanavan) 
 +* Fix gh-issue #31: add/improve configure checks for default CA bundle/path (Mike, @rcanavan)
+ Changes from beta1:
 -* Fixed PHP-5.3 compatibility
+ * Fixed recursive calls to the event loop dispatcher
  ]]></notes>
   <contents>
    <dir name="/">
index f83d0b4c3f9e62e36135e46fecd54dcaef761562,0bbda368adc8244a47742d3c123cf63f0da33175..311a4cd000afa5edccef34ab7e1bdcf7349e6bdb
@@@ -22,9 -22,7 +22,7 @@@ $env = $gen(
        "enable_maintainer_zts",
        "enable_json",
        "enable_hash" => ["yes"],
 -      "enable_iconv" => ["yes"]
 +      "enable_iconv" => ["yes"],
-       "enable_phar" => ["yes"],
-       "enable_posix" => ["yes"]
  ]);
  foreach ($env as $e) {
        printf(" - %s\n", $e);
Simple merge
index 225ce1cda8aa8828856880b7d5d23b1e0b6e3227,f4a995894ba8a2ddad3ce1cee1d71b6e165f2a3a..66edae664db2677cf0ef1490df05740415988cd1
@@@ -252,15 -283,11 +252,16 @@@ php_http_client_curl_ops_t *php_http_cl
        return &php_http_client_curl_user_ops;
  }
  
 -zend_class_entry *php_http_client_curl_user_class_entry;
 +static zend_class_entry *php_http_client_curl_user_class_entry;
 +
 +zend_class_entry *php_http_client_curl_user_get_class_entry()
 +{
 +      return php_http_client_curl_user_class_entry;
 +}
  
  ZEND_BEGIN_ARG_INFO_EX(ai_init, 0, 0, 1)
-       ZEND_ARG_TYPE_INFO(0, run, IS_CALLABLE, 0)
+       /* using IS_CALLABLE type hint would create a forwards compatibility break */
+       ZEND_ARG_INFO(0, run)
  ZEND_END_ARG_INFO();
  ZEND_BEGIN_ARG_INFO_EX(ai_timer, 0, 0, 1)
  #if PHP_VERSION_ID >= 70000
Simple merge
index 70f1005e6a3114f19800484d0a409584948c2c79,2ed6d7934c36773a9fdbcd2d635bb4ab84970289..1c8dc4f3528700708d342f08478461847e1fc591
@@@ -25,7 -23,7 +25,7 @@@ class UserHandler implements http\Clien
                $this->client = $client;
        }
        
--      function init(callable $run) {
++      function init($run) {
                $this->run = $run;
        }
        
index 1a09b8d3579dca58b2c05b4211f6c4ce48791ada,3378b628f3382ad4912af6cb13fd2ff0d7db254a..29205ecf16f0a8b763da910c8c36bf490ec50707
@@@ -8,12 -8,12 +8,12 @@@ include "skipif.inc"
  <?php
  echo "Test\n";
  
- $urls = [
+ $urls = array(
      "",
      "? = ="
];
);
  
 -$url0=new http\Url($urls[0]);
 +$url0=new http\Url($urls[0], null, http\Url::FROM_ENV);
  $url1=$url0->mod($urls[1]);
  
  echo $url1;
index 6cef7d9aef525ab3476976d0333101a879fa6c75,91310cb5094fd6d522bfe4c21a50b2eab5c6ca09..52c764852613e5d4a94e7c8cd7fd5a9a07695fc8
@@@ -30,10 -30,10 +30,10 @@@ try 
  ===DONE===
  --EXPECTF--
  Test
 -exception 'http\Exception\RuntimeException' with message 'http\Client::dequeue(): Could not dequeue request while executing callbacks' in %sgh-issue50.php:9
 +http\Exception\RuntimeException: http\Client::dequeue(): Could not dequeue request while executing callbacks in %sgh-issue50.php:9
  Stack trace:
  #0 %sgh-issue50.php(9): http\Client->dequeue(Object(http\Client\Request))
- #1 [internal function]: {closure}(Object(http\Client), Object(http\Client\Request), 18, 'GET / HTTP/1.1\r...')
+ #1 [internal function]: {closure}(Object(http\Client), Object(http\Client\Request), 18, 'GET / HTTP/1.1%s...')
  #2 %sgh-issue50.php(14): http\Client->send()
  #3 {main}
  ===DONE===