[PHP-CVS-DAILY] cvs: php-src / ChangeLog
changelog Wed Feb 6 01:31:28 2008 UTC Modified files: /php-srcChangeLog Log: ChangeLog update http://cvs.php.net/viewvc.cgi/php-src/ChangeLog?r1=1.2949r2=1.2950diff_format=u Index: php-src/ChangeLog diff -u php-src/ChangeLog:1.2949 php-src/ChangeLog:1.2950 --- php-src/ChangeLog:1.2949Tue Feb 5 01:31:32 2008 +++ php-src/ChangeLog Wed Feb 6 01:31:28 2008 @@ -1,3 +1,50 @@ +2008-02-05 Marcus Boerger [EMAIL PROTECTED] + +* (PHP_5_3) + ZendEngine2/zend_API.c: + - MFH Fix cross class tree reference issues with callbacks (colder,helly) + +* ZendEngine2/zend_API.c: + - Fix cross class tree reference issues with callbacks + +* ext/standard/tests/general_functions/callbacks_001.phpt + ext/standard/tests/general_functions/callbacks_001.phpt: + + - Add new test + +2008-02-05 Ilia Alshanetsky [EMAIL PROTECTED] + +* (PHP_5_2) + NEWS + ext/standard/array.c + ext/standard/array.c: + + MFB: Fixed bug #44046 (crash inside array_slice() function with an invalid + by-ref offset). + +* (PHP_5_3) + ext/standard/array.c: + + Fixed bug #44046 (crash inside array_slice() function with an invalid + by-ref offset). + +2008-02-05 Robert Nicholson [EMAIL PROTECTED] + +* ext/standard/tests/array/arsort_variation3.phpt + ext/standard/tests/array/arsort_variation3.phpt + ext/standard/tests/array/arsort_variation3.phpt: + - fix arsort_variation3.phpt which was missing its EXPECT section + +2008-02-05 Hannes Magnusson [EMAIL PROTECTED] + +* (PHP_5_3) + ZendEngine2/tests/access_modifiers_003.phpt + ZendEngine2/tests/lsb_006.phpt + ZendEngine2/tests/lsb_007.phpt + ZendEngine2/tests/lsb_008.phpt + ZendEngine2/tests/lsb_009.phpt: + Fix test + 2008-02-04 Marcus Boerger [EMAIL PROTECTED] * (PHP_5_2)
[PHP-CVS-DAILY] cvs: ZendEngine2 / ChangeLog
changelog Wed Feb 6 01:31:31 2008 UTC Modified files: /ZendEngine2ChangeLog Log: ChangeLog update http://cvs.php.net/viewvc.cgi/ZendEngine2/ChangeLog?r1=1.1234r2=1.1235diff_format=u Index: ZendEngine2/ChangeLog diff -u ZendEngine2/ChangeLog:1.1234 ZendEngine2/ChangeLog:1.1235 --- ZendEngine2/ChangeLog:1.1234Tue Feb 5 01:31:35 2008 +++ ZendEngine2/ChangeLog Wed Feb 6 01:31:30 2008 @@ -1,3 +1,22 @@ +2008-02-05 Marcus Boerger [EMAIL PROTECTED] + +* (PHP_5_3) + zend_API.c: + - MFH Fix cross class tree reference issues with callbacks (colder,helly) + +* zend_API.c: + - Fix cross class tree reference issues with callbacks + +2008-02-05 Hannes Magnusson [EMAIL PROTECTED] + +* (PHP_5_3) + tests/access_modifiers_003.phpt + tests/lsb_006.phpt + tests/lsb_007.phpt + tests/lsb_008.phpt + tests/lsb_009.phpt: + Fix test + 2008-02-04 Jani Taskinen [EMAIL PROTECTED] * (PHP_5_3) @@ -21172,7 +21191,7 @@ 2003-06-10 Jani Taskinen [EMAIL PROTECTED] * zend_multiply.h: - - Missing $Id: ChangeLog,v 1.1234 2008/02/05 01:31:35 changelog Exp $ tag + - Missing $Id: ChangeLog,v 1.1235 2008/02/06 01:31:30 changelog Exp $ tag 2003-06-10 James Cox [EMAIL PROTECTED] @@ -22896,7 +22915,7 @@ zend_types.h zend_variables.c zend_variables.h: - - Added some missing CVS $Id: ChangeLog,v 1.1234 2008/02/05 01:31:35 changelog Exp $ tags, headers and footers. + - Added some missing CVS $Id: ChangeLog,v 1.1235 2008/02/06 01:31:30 changelog Exp $ tags, headers and footers. 2003-01-30 Ilia Alshanetsky [EMAIL PROTECTED]
Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/array arsort_error.phpt arsort_variation1.phpt arsort_variation10.phpt arsort_variation11.phpt arsort_variation2.phpt arsort_variation3.phpt ars
arsort_variation3.phpt is missing expected output... -Hannes On Feb 4, 2008 1:05 AM, Robert Nicholson [EMAIL PROTECTED] wrote: nicholsrMon Feb 4 00:05:24 2008 UTC Added files: (Branch: PHP_5_3) /php-src/ext/standard/tests/array arsort_variation5.phpt arsort_variation9.phpt arsort_variation6.phpt arsort_variation4.phpt arsort_error.phpt arsort_variation3.phpt arsort_variation2.phpt arsort_variation1.phpt arsort_variation7.phpt arsort_variation11.phpt arsort_variation8.phpt arsort_variation10.phpt Log: - added some new tests for arsort http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation5.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation5.phpt +++ php-src/ext/standard/tests/array/arsort_variation5.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation9.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation9.phpt +++ php-src/ext/standard/tests/array/arsort_variation9.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation6.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation6.phpt +++ php-src/ext/standard/tests/array/arsort_variation6.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation4.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation4.phpt +++ php-src/ext/standard/tests/array/arsort_variation4.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_error.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_error.phpt +++ php-src/ext/standard/tests/array/arsort_error.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation3.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation3.phpt +++ php-src/ext/standard/tests/array/arsort_variation3.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation2.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation2.phpt +++ php-src/ext/standard/tests/array/arsort_variation2.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation1.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation1.phpt +++ php-src/ext/standard/tests/array/arsort_variation1.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation7.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation7.phpt +++ php-src/ext/standard/tests/array/arsort_variation7.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation11.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation11.phpt +++ php-src/ext/standard/tests/array/arsort_variation11.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation8.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation8.phpt +++ php-src/ext/standard/tests/array/arsort_variation8.phpt http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation10.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/array/arsort_variation10.phpt +++ php-src/ext/standard/tests/array/arsort_variation10.phpt -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/array arsort_variation3.phpt
nicholsrTue Feb 5 11:19:17 2008 UTC Modified files: (Branch: PHP_5_3) /php-src/ext/standard/tests/array arsort_variation3.phpt Log: - fix arsort_variation3.phpt which was missing its EXPECT section http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation3.phpt?r1=1.1.4.2r2=1.1.4.3diff_format=u Index: php-src/ext/standard/tests/array/arsort_variation3.phpt diff -u php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.4.2 php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.4.3 --- php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.4.2 Mon Feb 4 00:05:24 2008 +++ php-src/ext/standard/tests/array/arsort_variation3.phpt Tue Feb 5 11:19:17 2008 @@ -59,3 +59,268 @@ echo Done\n; ? +--EXPECT-- +*** Testing arsort() : usage variations *** + +-- Testing arsort() by supplying various integer/float arrays -- + +-- Iteration 1 -- +- With default sort_flag - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} + +-- Iteration 2 -- +- With default sort_flag - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} + +-- Iteration 3 -- +- With default sort_flag - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} + +-- Iteration 4 -- +- With default sort_flag - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +Done \ No newline at end of file -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php-src(PHP_5_2) /ext/standard/tests/array arsort_variation3.phpt
nicholsrTue Feb 5 11:18:00 2008 UTC Modified files: (Branch: PHP_5_2) /php-src/ext/standard/tests/array arsort_variation3.phpt Log: - fix arsort_variation3.phpt which was missing its EXPECT section http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/arsort_variation3.phpt?r1=1.1.2.1r2=1.1.2.2diff_format=u Index: php-src/ext/standard/tests/array/arsort_variation3.phpt diff -u php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.2.1 php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.2.2 --- php-src/ext/standard/tests/array/arsort_variation3.phpt:1.1.2.1 Mon Feb 4 00:04:25 2008 +++ php-src/ext/standard/tests/array/arsort_variation3.phpt Tue Feb 5 11:18:00 2008 @@ -59,3 +59,268 @@ echo Done\n; ? +--EXPECT-- +*** Testing arsort() : usage variations *** + +-- Testing arsort() by supplying various integer/float arrays -- + +-- Iteration 1 -- +- With default sort_flag - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(9) { + [8]= + int(41) + [5]= + int(31) + [3]= + int(21) + [1]= + int(11) + [7]= + int(0) + [2]= + int(-11) + [4]= + int(-21) + [6]= + int(-31) + [10]= + int(-41) +} + +-- Iteration 2 -- +- With default sort_flag - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(7) { + [3]= + float(1050) + [1]= + float(10.5) + [5]= + float(0.5) + [4]= + float(0.106) + [6]= + float(0.0001) + [7]= + float(-0.1) + [2]= + float(-10.5) +} + +-- Iteration 3 -- +- With default sort_flag - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(11) { + [11]= + int(33) + [7]= + int(2) + [9]= + float(0.106) + [6]= + float(0.09) + [2]= + float(0.0021) + [1]= + float(0.0001) + [5]= + int(0) + [3]= + float(-0.01) + [10]= + float(-0.106) + [8]= + float(-0.9) + [4]= + int(-1) +} + +-- Iteration 4 -- +- With default sort_flag - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +- Sort_flag = SORT_REGULAR - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +- Sort_flag = SORT_NUMERIC - +bool(true) +array(7) { + [2]= + float(2147483648) + [1]= + int(2147483647) + [6]= + int(0) + [5]= + int(0) + [3]= + int(-2147483647) + [4]= + float(-2147483648) + [7]= + float(-2147483649) +} +Done \ No newline at end of file -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/array arsort_variation3.phpt
On 05.02.2008 14:19, Robert Nicholson wrote: nicholsr Tue Feb 5 11:19:17 2008 UTC Modified files: (Branch: PHP_5_3) /php-src/ext/standard/tests/array arsort_variation3.phpt Log: - fix arsort_variation3.phpt which was missing its EXPECT section It seems that you still don't have a 64bit test machine. Want me to create an account on my server for you? -- Wbr, Antony Dovgal -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php-src /ext/standard/tests/general_functions callbacks_001.phpt
helly Tue Feb 5 18:56:40 2008 UTC Added files: /php-src/ext/standard/tests/general_functions callbacks_001.phpt Log: - Add new test http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/callbacks_001.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/general_functions/callbacks_001.phpt +++ php-src/ext/standard/tests/general_functions/callbacks_001.phpt --TEST-- ZE2 Callbacks of static functions --FILE-- ?php class A { public static function who() { echo A\n; } public static function who2() { echo A\n; } } class B extends A { public static function who() { echo B\n; } } class C extends B { public function call($cb) { echo join('|', $cb) . \n; call_user_func($cb); } public function test() { $this-call(array('parent', 'who')); $this-call(array('C', 'parent::who')); $this-call(array('B', 'parent::who')); $this-call(array('E', 'parent::who')); $this-call(array('A', 'who')); $this-call(array('C', 'who')); $this-call(array('B', 'who2')); } } class D { public static function who() { echo D\n; } } class E extends D { public static function who() { echo E\n; } } $o = new C; $o-test(); class O { public function who() { echo O\n; } } class P extends O { function __toString() { return '$this'; } public function who() { echo P\n; } public function call($cb) { echo join('|', $cb) . \n; call_user_func($cb); } public function test() { $this-call(array('parent', 'who')); $this-call(array('P', 'parent::who')); $this-call(array($this, 'O::who')); $this-call(array($this, 'B::who')); } } echo ===FOREIGN===\n; $o = new P; $o-test(); ? ===DONE=== --EXPECTF-- parent|who B C|parent::who B B|parent::who A E|parent::who D A|who A C|who B B|who2 A ===FOREIGN=== parent|who Strict Standards: call_user_func() expects parameter 1 to be a valid callback, non-static method O::who() should not be called statically, assuming $this from compatible context P in %s on line %d O P|parent::who Strict Standards: call_user_func() expects parameter 1 to be a valid callback, non-static method O::who() should not be called statically, assuming $this from compatible context P in %s on line %d O $this|O::who O $this|B::who Warning: call_user_func() expects parameter 1 to be a valid callback, class 'P' is not a subclass of 'B' in %s on line %d ===DONE=== -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php-src(PHP_5_3) /ext/standard/tests/general_functions callbacks_001.phpt
helly Tue Feb 5 19:08:42 2008 UTC Added files: (Branch: PHP_5_3) /php-src/ext/standard/tests/general_functions callbacks_001.phpt Log: - MFH Add new test http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/general_functions/callbacks_001.phpt?view=markuprev=1.1 Index: php-src/ext/standard/tests/general_functions/callbacks_001.phpt +++ php-src/ext/standard/tests/general_functions/callbacks_001.phpt --TEST-- ZE2 Callbacks of static functions --FILE-- ?php class A { public static function who() { echo A\n; } public static function who2() { echo A\n; } } class B extends A { public static function who() { echo B\n; } } class C extends B { public function call($cb) { echo join('|', $cb) . \n; call_user_func($cb); } public function test() { $this-call(array('parent', 'who')); $this-call(array('C', 'parent::who')); $this-call(array('B', 'parent::who')); $this-call(array('E', 'parent::who')); $this-call(array('A', 'who')); $this-call(array('C', 'who')); $this-call(array('B', 'who2')); } } class D { public static function who() { echo D\n; } } class E extends D { public static function who() { echo E\n; } } $o = new C; $o-test(); class O { public function who() { echo O\n; } } class P extends O { function __toString() { return '$this'; } public function who() { echo P\n; } public function call($cb) { echo join('|', $cb) . \n; call_user_func($cb); } public function test() { $this-call(array('parent', 'who')); $this-call(array('P', 'parent::who')); $this-call(array($this, 'O::who')); $this-call(array($this, 'B::who')); } } echo ===FOREIGN===\n; $o = new P; $o-test(); ? ===DONE=== --EXPECTF-- parent|who B C|parent::who B B|parent::who A E|parent::who D A|who A C|who B B|who2 A ===FOREIGN=== parent|who Strict Standards: call_user_func() expects parameter 1 to be a valid callback, non-static method O::who() should not be called statically, assuming $this from compatible context P in %s on line %d O P|parent::who Strict Standards: call_user_func() expects parameter 1 to be a valid callback, non-static method O::who() should not be called statically, assuming $this from compatible context P in %s on line %d O $this|O::who O $this|B::who Warning: call_user_func() expects parameter 1 to be a valid callback, class 'P' is not a subclass of 'B' in %s on line %d ===DONE=== -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php-src /ext/standard file.c
felipe Wed Feb 6 02:56:49 2008 UTC Modified files: /php-src/ext/standard file.c Log: Fixed bug #42167 (fgetcsv gives different output on php6 compared to php5), #42219 (length argument of fgetcsv() is not effective/working in PHP6) http://cvs.php.net/viewvc.cgi/php-src/ext/standard/file.c?r1=1.506r2=1.507diff_format=u Index: php-src/ext/standard/file.c diff -u php-src/ext/standard/file.c:1.506 php-src/ext/standard/file.c:1.507 --- php-src/ext/standard/file.c:1.506 Mon Feb 4 19:48:14 2008 +++ php-src/ext/standard/file.c Wed Feb 6 02:56:49 2008 @@ -21,7 +21,7 @@ +--+ */ -/* $Id: file.c,v 1.506 2008/02/04 19:48:14 felipe Exp $ */ +/* $Id: file.c,v 1.507 2008/02/06 02:56:49 felipe Exp $ */ /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */ @@ -2158,7 +2158,7 @@ } if (stream-readbuf_type == IS_STRING) { - /* Binary mode stream needs binary delmiter/enclosure */ + /* Binary mode stream needs binary delimiter/enclosure */ if (delimiter_type == IS_UNICODE) { if (FAILURE == zend_unicode_to_string(ZEND_U_CONVERTER(UG(runtime_encoding_conv)), delimiter, delimiter_len, (UChar*)delimiter, delimiter_len TSRMLS_CC)) { php_error_docref(NULL TSRMLS_CC, E_WARNING, Failed converting delimiter from unicode); @@ -2211,7 +2211,17 @@ } } - buf.v = php_stream_get_line_ex(stream, stream-readbuf_type, NULL_ZSTR, 0, (len 0) ? 0 : len, buf_len); + if (len 0) { + buf.v = php_stream_get_line_ex(stream, stream-readbuf_type, NULL_ZSTR, 0, 0, buf_len); + } else { + buf.v = stream-readbuf_type == IS_UNICODE ? emalloc(UBYTES(len + 1)) : emalloc(len + 1); + if (php_stream_get_line_ex(stream, stream-readbuf_type, buf, len + 1, len + 1, buf_len) == NULL) { + efree(buf.v); + RETVAL_FALSE; + goto cleanup; + } + } + if (!buf.v) { /* No data */ RETVAL_FALSE; @@ -2473,7 +2483,7 @@ case PHP_FGETCSV_FIELD_NO_ENC: /* Check for escapes */ - if (PHP_FGETCSV_BIN_CHECK(p, e, escape, escape_len)) { + if (!PHP_FGETCSV_BIN_CHECK(p, e, delimiter, delimiter_len) PHP_FGETCSV_BIN_CHECK(p, e, escape, escape_len)) { p += escape_len + 1; } @@ -2682,7 +2692,7 @@ case PHP_FGETCSV_FIELD_NO_ENC: /* Check for escapes */ - if (PHP_FGETCSV_UNI_CHECK(p, e, escape, escape_len)) { + if (!PHP_FGETCSV_UNI_CHECK(p, e, delimiter, delimiter_len) PHP_FGETCSV_UNI_CHECK(p, e, escape, escape_len)) { p += escape_len + 1; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php