scottmac Thu, 14 Jul 2011 18:49:12 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=313251
Log: Fix prototypes for ldap_control_paged_result and fix function name in tests Changed paths: U php/php-src/branches/PHP_5_4/ext/ldap/ldap.c U php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation1.phpt U php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation3.phpt U php/php-src/trunk/ext/ldap/ldap.c U php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation1.phpt U php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation3.phpt Modified: php/php-src/branches/PHP_5_4/ext/ldap/ldap.c =================================================================== --- php/php-src/branches/PHP_5_4/ext/ldap/ldap.c 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/branches/PHP_5_4/ext/ldap/ldap.c 2011-07-14 18:49:12 UTC (rev 313251) @@ -2186,7 +2186,7 @@ #endif #ifdef LDAP_CONTROL_PAGEDRESULTS -/* {{{ proto bool ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) +/* {{{ proto mixed ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) Inject paged results control*/ PHP_FUNCTION(ldap_control_paged_result) { @@ -2278,7 +2278,7 @@ } /* }}} */ -/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string cookie [, int estimated]]) +/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string &cookie [, int &estimated]]) Extract paged results control response */ PHP_FUNCTION(ldap_control_paged_result_response) { @@ -2292,7 +2292,6 @@ ber_tag_t tag; int rc, lerrcode, myargcount = ZEND_NUM_ARGS(); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rr|zz", &link, &result, &cookie, &estimated) != SUCCESS) { return; } Modified: php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation1.phpt =================================================================== --- php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation1.phpt 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation1.phpt 2011-07-14 18:49:12 UTC (rev 313251) @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page) +ldap_ldap_control_paged_result() test (fetching the first page) --CREDITS-- Jean-Sebastien Hedde <jean...@au-fil-du.net> --SKIPIF-- @@ -17,7 +17,7 @@ $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_control_paged_results($link, 1), + ldap_control_paged_result($link, 1), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); Modified: php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation3.phpt =================================================================== --- php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation3.phpt 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/branches/PHP_5_4/ext/ldap/tests/ldap_control_paged_results_variation3.phpt 2011-07-14 18:49:12 UTC (rev 313251) @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page then the next final page) +ldap_ldap_control_paged_result() test (fetching the first page then the next final page) --CREDITS-- Jean-Sebastien Hedde <jean...@au-fil-du.net> --SKIPIF-- @@ -18,11 +18,11 @@ $filter = "(cn=*)"; $cookie = ''; var_dump( - ldap_control_paged_results($link, 2, true, $cookie), + ldap_control_paged_result($link, 2, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result), - ldap_control_paged_results_response($link, $result, $cookie), - ldap_control_paged_results($link, 20, true, $cookie), + ldap_control_paged_result_response($link, $result, $cookie), + ldap_control_paged_result($link, 20, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); Modified: php/php-src/trunk/ext/ldap/ldap.c =================================================================== --- php/php-src/trunk/ext/ldap/ldap.c 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/trunk/ext/ldap/ldap.c 2011-07-14 18:49:12 UTC (rev 313251) @@ -2186,7 +2186,7 @@ #endif #ifdef LDAP_CONTROL_PAGEDRESULTS -/* {{{ proto bool ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) +/* {{{ proto mixed ldap_control_paged_result(resource link, int pagesize [, bool iscritical [, string cookie]]) Inject paged results control*/ PHP_FUNCTION(ldap_control_paged_result) { @@ -2278,7 +2278,7 @@ } /* }}} */ -/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string cookie [, int estimated]]) +/* {{{ proto bool ldap_control_paged_result_response(resource link, resource result [, string &cookie [, int &estimated]]) Extract paged results control response */ PHP_FUNCTION(ldap_control_paged_result_response) { @@ -2292,7 +2292,6 @@ ber_tag_t tag; int rc, lerrcode, myargcount = ZEND_NUM_ARGS(); - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rr|zz", &link, &result, &cookie, &estimated) != SUCCESS) { return; } Modified: php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation1.phpt =================================================================== --- php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation1.phpt 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation1.phpt 2011-07-14 18:49:12 UTC (rev 313251) @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page) +ldap_ldap_control_paged_result() test (fetching the first page) --CREDITS-- Jean-Sebastien Hedde <jean...@au-fil-du.net> --SKIPIF-- @@ -17,7 +17,7 @@ $dn = "dc=my-domain,dc=com"; $filter = "(cn=*)"; var_dump( - ldap_control_paged_results($link, 1), + ldap_control_paged_result($link, 1), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) ); Modified: php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation3.phpt =================================================================== --- php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation3.phpt 2011-07-14 17:58:16 UTC (rev 313250) +++ php/php-src/trunk/ext/ldap/tests/ldap_control_paged_results_variation3.phpt 2011-07-14 18:49:12 UTC (rev 313251) @@ -1,5 +1,5 @@ --TEST-- -ldap_ldap_control_paged_results() test (fetching the first page then the next final page) +ldap_ldap_control_paged_result() test (fetching the first page then the next final page) --CREDITS-- Jean-Sebastien Hedde <jean...@au-fil-du.net> --SKIPIF-- @@ -18,11 +18,11 @@ $filter = "(cn=*)"; $cookie = ''; var_dump( - ldap_control_paged_results($link, 2, true, $cookie), + ldap_control_paged_result($link, 2, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result), - ldap_control_paged_results_response($link, $result, $cookie), - ldap_control_paged_results($link, 20, true, $cookie), + ldap_control_paged_result_response($link, $result, $cookie), + ldap_control_paged_result($link, 20, true, $cookie), $result = ldap_search($link, $dn, $filter, array('cn')), ldap_get_entries($link, $result) );
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php