[PHP-BUG] Bug #65538 [NEW]: cafile option of ssl stream context does not work with stream wrappers

2013-08-24 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.5Git-2013-08-24 (Git)
Package:  OpenSSL related
Bug Type: Bug
Bug description:cafile option of ssl stream context does not work with stream 
wrappers

Description:

The SSL stream context's "cafile" option expects the name of a file. When
this name is not a "normal" filename but, for instance,
"phar://phar-alias/ca.pem" I get the following error

  Unable to set verify locations `phar://phpunit-3.8-gb5ac7cc.phar/ca.pem'

This looks to me like stream wrappers are not applied in this context.

This makes it impossible to ship a PHAR that contains a CA file and use
that to verify the peer (without copying it from the PHAR to a temporary
file).


-- 
Edit bug report at https://bugs.php.net/bug.php?id=65538&edit=1
-- 
Try a snapshot (PHP 5.4):   
https://bugs.php.net/fix.php?id=65538&r=trysnapshot54
Try a snapshot (PHP 5.3):   
https://bugs.php.net/fix.php?id=65538&r=trysnapshot53
Try a snapshot (trunk): 
https://bugs.php.net/fix.php?id=65538&r=trysnapshottrunk
Fixed in SVN:   https://bugs.php.net/fix.php?id=65538&r=fixed
Fixed in release:   https://bugs.php.net/fix.php?id=65538&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=65538&r=needtrace
Need Reproduce Script:  https://bugs.php.net/fix.php?id=65538&r=needscript
Try newer version:  https://bugs.php.net/fix.php?id=65538&r=oldversion
Not developer issue:https://bugs.php.net/fix.php?id=65538&r=support
Expected behavior:  https://bugs.php.net/fix.php?id=65538&r=notwrong
Not enough info:
https://bugs.php.net/fix.php?id=65538&r=notenoughinfo
Submitted twice:
https://bugs.php.net/fix.php?id=65538&r=submittedtwice
register_globals:   https://bugs.php.net/fix.php?id=65538&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65538&r=php4
Daylight Savings:   https://bugs.php.net/fix.php?id=65538&r=dst
IIS Stability:  https://bugs.php.net/fix.php?id=65538&r=isapi
Install GNU Sed:https://bugs.php.net/fix.php?id=65538&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=65538&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=65538&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=65538&r=mysqlcfg



[PHP-BUG] Req #61602 [NEW]: Allow access to name of constant used as default value

2012-04-02 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.4Git-2012-04-02 (Git)
Package:  Reflection related
Bug Type: Feature/Change Request
Bug description:Allow access to name of constant used as default value

Description:

When a constant is used for the default value of an optional parameter, the
Reflection API (tries to) resolve(s) the constant to its value and then
returns it as the default value.

In addition, I would like to have two additional methods in
ReflectionParameter that expose 1) whether or not a default value "is a"
constant and 2) the name of the constant.

In the example below, I am using temporary names ("defaultValueIsConstant"
and "getDefaultValueConstantName") for these two methods because I cannot
think of sensible method names right now.

Test script:
---
getParameters();

foreach ($p as $_p) {
var_dump($_p->getDefaultValue());

if ($_p->defaultValueIsConstant()) {
var_dump($_p->getDefaultValueConstantName());
}
}

Expected result:

string(3) "..."
string(9) "self::bar"

Actual result:
--
string(3) "..."

-- 
Edit bug report at https://bugs.php.net/bug.php?id=61602&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=61602&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=61602&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=61602&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=61602&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=61602&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=61602&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=61602&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=61602&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=61602&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=61602&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=61602&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=61602&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=61602&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=61602&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=61602&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=61602&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=61602&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=61602&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=61602&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=61602&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=61602&r=mysqlcfg



Req #61602 [Com]: Allow access to name of constant used as default value

2012-04-03 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=61602&edit=1

 ID: 61602
 Comment by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow access to name of constant used as default
 value
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:5.4Git-2012-04-02 (Git)
 Block user comment: N
 Private report: N

 New Comment:

Any chance this pull request will be merged into PHP 5.4.1? Thanks.


Previous Comments:

[2012-04-03 06:07:04] reeze dot xia at gmail dot com

PS:

@pierrick pull request is here https://github.com/php/php-src/pull/35.

thanks.


[2012-04-03 05:56:12] reeze dot xia at gmail dot com

Hi, pierrick & sebastian:
   I have create another patch for this request. it differ's in:

   - rename defaultValueIsConstant to isDefaultValueConstant to match bool 
return values's is* method naming.
   - handle global constant.
   - refactor code to remove duplicate.
   - add 3 tests for it.

and I've make test everything looks fine.

please review it for me.

Thanks.


[2012-04-03 00:24:13] pierr...@php.net

Just created a quick patch. If it's Ok with everybody I'll commit it to master 
with tests.


[2012-04-03 00:23:24] pierr...@php.net

The following patch has been added/updated:

Patch Name: getDefaultValueConstantName.diff
Revision:   1333412604
URL:
https://bugs.php.net/patch-display.php?bug=61602&patch=getDefaultValueConstantName.diff&revision=1333412604


[2012-04-02 14:34:44] der...@php.net

It's definitely possible, I've just added something like this to VLD: 
https://github.com/derickr/vld/commit/f22862bfa8620780906f0e692f929a543264b5f8




The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

https://bugs.php.net/bug.php?id=61602


-- 
Edit this bug report at https://bugs.php.net/bug.php?id=61602&edit=1


[PHP-BUG] Bug #64910 [NEW]: Line number of $e = new Exception vs. line number of throw $e

2013-05-23 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.5Git-2013-05-23 (Git)
Package:  Scripting Engine problem
Bug Type: Bug
Bug description:Line number of $e = new Exception vs. line number of throw $e

Description:

The error message that is created for an uncaught exception as well as the
stacktrace of an exception list the number of the line on which the
exception object was created. I would expect this to be number of the line
on which the exception is raised using the throw statement.

Also note that the documentation on this is inconsistent: the
Exception::getLine() method is documented with "Gets the line in which the
exception occurred" whereas the Exception::$line attribute is documented
with "The line where the exception was created".

Test script:
---
https://bugs.php.net/bug.php?id=64910&edit=1
-- 
Try a snapshot (PHP 5.4):   
https://bugs.php.net/fix.php?id=64910&r=trysnapshot54
Try a snapshot (PHP 5.3):   
https://bugs.php.net/fix.php?id=64910&r=trysnapshot53
Try a snapshot (trunk): 
https://bugs.php.net/fix.php?id=64910&r=trysnapshottrunk
Fixed in SVN:   https://bugs.php.net/fix.php?id=64910&r=fixed
Fixed in release:   https://bugs.php.net/fix.php?id=64910&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=64910&r=needtrace
Need Reproduce Script:  https://bugs.php.net/fix.php?id=64910&r=needscript
Try newer version:  https://bugs.php.net/fix.php?id=64910&r=oldversion
Not developer issue:https://bugs.php.net/fix.php?id=64910&r=support
Expected behavior:  https://bugs.php.net/fix.php?id=64910&r=notwrong
Not enough info:
https://bugs.php.net/fix.php?id=64910&r=notenoughinfo
Submitted twice:
https://bugs.php.net/fix.php?id=64910&r=submittedtwice
register_globals:   https://bugs.php.net/fix.php?id=64910&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=64910&r=php4
Daylight Savings:   https://bugs.php.net/fix.php?id=64910&r=dst
IIS Stability:  https://bugs.php.net/fix.php?id=64910&r=isapi
Install GNU Sed:https://bugs.php.net/fix.php?id=64910&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=64910&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=64910&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=64910&r=mysqlcfg



[PHP-BUG] Bug #65094 [NEW]: php.ini is not found by PHP CLI

2013-06-21 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.5.0
Package:  *General Issues
Bug Type: Bug
Bug description:php.ini is not found by PHP CLI

Description:

PHP CLI interpreter does not find php.ini configuration file.

Expected result:

./configure --prefix=/tmp/php-5.5.0
make
make install

➜  php-5.5.0  /tmp/php-5.5.0/bin/php -i | grep ini
Configuration File (php.ini) Path => /tmp/php-5.5.0/lib


vi /tmp/php-5.5.0/lib/php.ini

➜  php-5.5.0  /tmp/php-5.5.0/bin/php -i | grep Loaded
Loaded Configuration File => /tmp/php-5.5.0/lib/php.ini

Actual result:
--
./configure --prefix=/tmp/php-5.5.0
make
make install

➜  php-5.5.0  /tmp/php-5.5.0/bin/php -i | grep ini
Configuration File (php.ini) Path => /tmp/php-5.5.0/lib


vi /tmp/php-5.5.0/lib/php.ini

➜  php-5.5.0  /tmp/php-5.5.0/bin/php -i|grep Loaded
Loaded Configuration File => (none)

-- 
Edit bug report at https://bugs.php.net/bug.php?id=65094&edit=1
-- 
Try a snapshot (PHP 5.4):   
https://bugs.php.net/fix.php?id=65094&r=trysnapshot54
Try a snapshot (PHP 5.3):   
https://bugs.php.net/fix.php?id=65094&r=trysnapshot53
Try a snapshot (trunk): 
https://bugs.php.net/fix.php?id=65094&r=trysnapshottrunk
Fixed in SVN:   https://bugs.php.net/fix.php?id=65094&r=fixed
Fixed in release:   https://bugs.php.net/fix.php?id=65094&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=65094&r=needtrace
Need Reproduce Script:  https://bugs.php.net/fix.php?id=65094&r=needscript
Try newer version:  https://bugs.php.net/fix.php?id=65094&r=oldversion
Not developer issue:https://bugs.php.net/fix.php?id=65094&r=support
Expected behavior:  https://bugs.php.net/fix.php?id=65094&r=notwrong
Not enough info:
https://bugs.php.net/fix.php?id=65094&r=notenoughinfo
Submitted twice:
https://bugs.php.net/fix.php?id=65094&r=submittedtwice
register_globals:   https://bugs.php.net/fix.php?id=65094&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65094&r=php4
Daylight Savings:   https://bugs.php.net/fix.php?id=65094&r=dst
IIS Stability:  https://bugs.php.net/fix.php?id=65094&r=isapi
Install GNU Sed:https://bugs.php.net/fix.php?id=65094&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=65094&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=65094&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=65094&r=mysqlcfg



[PHP-BUG] Bug #65135 [NEW]: Support for non-scalar keys in foreach() does not work with SplObjectStorage

2013-06-26 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.5.0
Package:  SPL related
Bug Type: Bug
Bug description:Support for non-scalar keys in foreach() does not work with 
SplObjectStorage

Description:

Quoting from https://wiki.php.net/rfc/foreach-non-scalar-keys

  // NOT possible
  foreach ($objectStore as $key => $value) {
// ...
  }
 
  // Instead you have to use
  foreach ($objectStore as $key) {
$value = $objectStore[$key];
 
// ...
  }

This suggests that it would work after the proposed changes. However, in
PHP 5.5 (for which the RFC was accepted) this still does not work.

Test script:
---
attach(new DateTime, new StdClass);

foreach ($o as $key => $value) {
var_dump($key);
var_dump($value);
}

Expected result:

class DateTime#2 (3) {
  public $date =>
  string(19) "2013-06-26 18:04:30"
  public $timezone_type =>
  int(3)
  public $timezone =>
  string(13) "Europe/Berlin"
}
class stdClass#3 (0) {
}

Actual result:
--
int(0)
class DateTime#2 (3) {
  public $date =>
  string(19) "2013-06-26 18:03:24"
  public $timezone_type =>
  int(3)
  public $timezone =>
  string(13) "Europe/Berlin"
}

-- 
Edit bug report at https://bugs.php.net/bug.php?id=65135&edit=1
-- 
Try a snapshot (PHP 5.4):   
https://bugs.php.net/fix.php?id=65135&r=trysnapshot54
Try a snapshot (PHP 5.3):   
https://bugs.php.net/fix.php?id=65135&r=trysnapshot53
Try a snapshot (trunk): 
https://bugs.php.net/fix.php?id=65135&r=trysnapshottrunk
Fixed in SVN:   https://bugs.php.net/fix.php?id=65135&r=fixed
Fixed in release:   https://bugs.php.net/fix.php?id=65135&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=65135&r=needtrace
Need Reproduce Script:  https://bugs.php.net/fix.php?id=65135&r=needscript
Try newer version:  https://bugs.php.net/fix.php?id=65135&r=oldversion
Not developer issue:https://bugs.php.net/fix.php?id=65135&r=support
Expected behavior:  https://bugs.php.net/fix.php?id=65135&r=notwrong
Not enough info:
https://bugs.php.net/fix.php?id=65135&r=notenoughinfo
Submitted twice:
https://bugs.php.net/fix.php?id=65135&r=submittedtwice
register_globals:   https://bugs.php.net/fix.php?id=65135&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65135&r=php4
Daylight Savings:   https://bugs.php.net/fix.php?id=65135&r=dst
IIS Stability:  https://bugs.php.net/fix.php?id=65135&r=isapi
Install GNU Sed:https://bugs.php.net/fix.php?id=65135&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=65135&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=65135&r=nozend
MySQL Configuration Error:  https://bugs.php.net/fix.php?id=65135&r=mysqlcfg



Req #61602 [Com]: Allow access to name of constant used as default value

2012-04-24 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=61602&edit=1

 ID: 61602
 Comment by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow access to name of constant used as default
 value
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:5.4Git-2012-04-02 (Git)
 Block user comment: N
 Private report: N

 New Comment:

Can we at least merge the patch into master? Once it's there we can think about 
merging it into PHP 5.4 for PHP 5.4.2.


Previous Comments:

[2012-04-08 00:45:21] s...@php.net

Not very likely for 5.4.1, doesn't seem to be a critical bug. For 5.4.2, maybe.


[2012-04-03 09:22:42] sebast...@php.net

Any chance this pull request will be merged into PHP 5.4.1? Thanks.


[2012-04-03 06:07:04] reeze dot xia at gmail dot com

PS:

@pierrick pull request is here https://github.com/php/php-src/pull/35.

thanks.


[2012-04-03 05:56:12] reeze dot xia at gmail dot com

Hi, pierrick & sebastian:
   I have create another patch for this request. it differ's in:

   - rename defaultValueIsConstant to isDefaultValueConstant to match bool 
return values's is* method naming.
   - handle global constant.
   - refactor code to remove duplicate.
   - add 3 tests for it.

and I've make test everything looks fine.

please review it for me.

Thanks.


[2012-04-03 00:24:13] pierr...@php.net

Just created a quick patch. If it's Ok with everybody I'll commit it to master 
with tests.




The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

https://bugs.php.net/bug.php?id=61602


-- 
Edit this bug report at https://bugs.php.net/bug.php?id=61602&edit=1


[PHP-BUG] Bug #51697 [NEW]: Segfault in spl_iterators.c

2010-04-29 Thread sebast...@php.net
From: sebastian
Operating system: Linux
PHP version:  5.3SVN-2010-04-29 (SVN)
Package:  SPL related
Bug Type: Bug
Bug description:Segfault in spl_iterators.c

Description:

Segfault in spl_iterators.c.

Test script:
---
No short/reproducing script available.

Expected result:

No segfault.

Actual result:
--
s...@vmware phpunit-mock-objects % gdb /usr/local/php-5.4/bin/php

GNU gdb (GDB) 7.0-ubuntu

Copyright (C) 2009 Free Software Foundation, Inc.

License GPLv3+: GNU GPL version 3 or later


This is free software: you are free to change and redistribute it.

There is NO WARRANTY, to the extent permitted by law.  Type "show copying"

and "show warranty" for details.

This GDB was configured as "x86_64-linux-gnu".

For bug reporting instructions, please see:

...

Reading symbols from /usr/local/php-5.4/bin/php...done.

(gdb) r /usr/local/bin/phpunit Tests

Starting program: /usr/local/php-5.4/bin/php /usr/local/bin/phpunit Tests

[Thread debugging using libthread_db enabled]



Warning:
require_once(/usr/local/src/phpunit-mock-objects/_files/AbstractMockTestClass.php):
failed to open stream: No such file or directory in
/usr/local/src/phpunit-mock-objects/Tests/MockObjectTest.php on line 48



Fatal error: require_once(): Failed opening required
'/usr/local/src/phpunit-mock-objects/_files/AbstractMockTestClass.php'
(include_path='/usr/local/src/phpunit:.:/usr/local/src/phpunit:/usr/local/src/phpunit-mock-objects:/usr/local/php-5.3/lib/php:/usr/local/src/file-iterator:/usr/local/src/tokenstream:/usr/local/src/text-template:/usr/local/src/code-coverage:/usr/local/src/hamcrest/hamcrest:/usr/local/src/hamcrest:')
in /usr/local/src/phpunit-mock-objects/Tests/MockObjectTest.php on line 48



Program received signal SIGSEGV, Segmentation fault.

0x007775c4 in spl_recursive_it_dtor (_iter=0x151e760) at
/usr/local/src/php/src/trunk/ext/spl/spl_iterators.c:135

135 sub_iter = object->iterators[object->level].iterator;

(gdb) bt

#0  0x007775c4 in spl_recursive_it_dtor (_iter=0x151e760) at
/usr/local/src/php/src/trunk/ext/spl/spl_iterators.c:135

#1  0x0077e152 in spl_dual_it_free_storage (_object=0x15222f8) at
/usr/local/src/php/src/trunk/ext/spl/spl_iterators.c:1920

#2  0x009776d7 in zend_objects_store_free_object_storage
(objects=0x12268b8) at
/usr/local/src/php/src/trunk/Zend/zend_objects_API.c:92

#3  0x0092f1aa in shutdown_executor () at
/usr/local/src/php/src/trunk/Zend/zend_execute_API.c:302

#4  0x009449a4 in zend_deactivate () at
/usr/local/src/php/src/trunk/Zend/zend.c:897

#5  0x008b96e5 in php_request_shutdown (dummy=0x0) at
/usr/local/src/php/src/trunk/main/main.c:1669

#6  0x00a8625f in main (argc=3, argv=0x7fffe768) at
/usr/local/src/php/src/trunk/sapi/cli/php_cli.c:1385



-- 
Edit bug report at http://bugs.php.net/bug.php?id=51697&edit=1
-- 
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=51697&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=51697&r=trysnapshot53
Try a snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=51697&r=trysnapshot60
Fixed in SVN:
http://bugs.php.net/fix.php?id=51697&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=51697&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=51697&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=51697&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=51697&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=51697&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=51697&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=51697&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=51697&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=51697&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=51697&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=51697&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=51697&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=51697&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=51697&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=51697&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=51697&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=51697&r=mysqlcfg



[PHP-BUG] Bug #53144 [NEW]: Segfault in zend_hash_get_current_data_ex

2010-10-24 Thread sebast...@php.net
From: sebastian
Operating system: Linux
PHP version:  5.3SVN-2010-10-24 (SVN)
Package:  Scripting Engine problem
Bug Type: Bug
Bug description:Segfault in zend_hash_get_current_data_ex

Description:

I can only reproduce this with PHPUnit and the Symfony2 testsuite.

Expected result:

No segfault.

Actual result:
--
GNU gdb (GDB) 7.1-ubuntu

Copyright (C) 2010 Free Software Foundation, Inc.

License GPLv3+: GNU GPL version 3 or later


This is free software: you are free to change and redistribute it.

There is NO WARRANTY, to the extent permitted by law.  Type "show copying"

and "show warranty" for details.

This GDB was configured as "x86_64-linux-gnu".

For bug reporting instructions, please see:

...

Reading symbols from /usr/local/php-5.3/bin/php...done.

(gdb) r /usr/local/bin/phpunit --filter CrawlerTest::testClear

Starting program: /usr/local/php-5.3/bin/php /usr/local/bin/phpunit
--filter CrawlerTest::testClear

[Thread debugging using libthread_db enabled]

PHPUnit @package_version@ by Sebastian Bergmann.





Program received signal SIGSEGV, Segmentation fault.

0x00955383 in zend_hash_get_current_data_ex (ht=0x54892f8,
pData=0x7fffb9a0, pos=0x7fffb998) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_hash.c:1166

1166*pData = p->pData;

(gdb) bt

#0  0x00955383 in zend_hash_get_current_data_ex (ht=0x54892f8,
pData=0x7fffb9a0, pos=0x7fffb998) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_hash.c:1166

#1  0x00797dbb in zim_spl_SplObjectStorage_removeAll (ht=1,
return_value=0x5476948, return_value_ptr=0x0, this_ptr=0x5476de8,
return_value_used=0) at
/usr/local/src/php/src/branches/PHP_5_3/ext/spl/spl_observer.c:424

#2  0x00979b35 in zend_do_fcall_common_helper_SPEC
(execute_data=0x77e7dd08) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:316

#3  0x0097a2c0 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0x77e7dd08) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:421

#4  0x00978eea in execute (op_array=0x5478880) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:107

#5  0x00932ba0 in zend_call_function (fci=0x7fffbd20,
fci_cache=0x7fffbd70) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_execute_API.c:964

#6  0x006f6efc in zim_reflection_method_invokeArgs (ht=2,
return_value=0x5476f78, return_value_ptr=0x0, this_ptr=0x5477420,
return_value_used=1) at
/usr/local/src/php/src/branches/PHP_5_3/ext/reflection/php_reflection.c:2738

#7  0x00979b35 in zend_do_fcall_common_helper_SPEC
(execute_data=0x77e7cea8) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:316

#8  0x0097a2c0 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0x77e7cea8) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:421

#9  0x00978eea in execute (op_array=0x4bb6c18) at
/usr/local/src/php/src/branches/PHP_5_3/Zend/zend_vm_execute.h:107

#10 0x00943599 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /usr/local/src/php/src/branches/PHP_5_3/Zend/zend.c:1194

#11 0x008c3e34 in php_execute_script (primary_file=0x7fffe4a0)
at /usr/local/src/php/src/branches/PHP_5_3/main/main.c:2260

#12 0x00a3083a in main (argc=4, argv=0x7fffe708) at
/usr/local/src/php/src/branches/PHP_5_3/sapi/cli/php_cli.c:1193









==16795== Memcheck, a memory error detector

==16795== Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al.

==16795== Using Valgrind-3.6.0.SVN-Debian and LibVEX; rerun with -h for
copyright info

==16795== Command: /usr/local/php-5.3/bin/php /usr/local/bin/phpunit
--filter CrawlerTest::testClear

==16795== Parent PID: 18102

==16795== 

==16795== Invalid read of size 8

==16795==at 0x955141: zend_hash_move_forward_ex (zend_hash.c:1089)

==16795==by 0x797D9F: zim_spl_SplObjectStorage_removeAll
(spl_observer.c:426)

==16795==by 0x979B34: zend_do_fcall_common_helper_SPEC
(zend_vm_execute.h:316)

==16795==by 0x97A2BF: ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(zend_vm_execute.h:421)

==16795==by 0x978EE9: execute (zend_vm_execute.h:107)

==16795==by 0x932B9F: zend_call_function (zend_execute_API.c:964)

==16795==by 0x6F6EFB: zim_reflection_method_invokeArgs
(php_reflection.c:2738)

==16795==by 0x979B34: zend_do_fcall_common_helper_SPEC
(zend_vm_execute.h:316)

==16795==by 0x97A2BF: ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(zend_vm_execute.h:421)

==16795==by 0x978EE9: execute (zend_vm_execute.h:107)

==16795==by 0x943598: zend_execute_scripts (zend.c:1194)

==16795==by 0x8C3E33: php_execute_script (main.c:2260)

==16795==  Address 0xd4bbfd0 is 32 bytes inside a block of size 87 free'd

==16795==at 0x4C270BD: free (vg_replace_malloc.c:366)

==16795=

[PHP-BUG] Bug #53347 [NEW]: Segfault in zend_is_inconsistent()

2010-11-18 Thread sebast...@php.net
From: sebastian
Operating system: Linux
PHP version:  trunk-SVN-2010-11-18 (SVN)
Package:  Reproducible crash
Bug Type: Bug
Bug description:Segfault in zend_is_inconsistent()

Description:

PHP 5.3.99 (current trunk) segfaults in zend_is_inconsistent().

Test script:
---
The segfault is triggered by code that is part of ezcConsoleTools, for
instance by just invoking phploc on the commandline. Unfortunately, I was
not able to reduce this further, yet.

Expected result:

No segfault.

Actual result:
--
s...@thinkpad ~ % USE_ZEND_ALLOC=0 valgrind --leak-check=full php
/usr/local/src/phploc/phploc.php

==1760== Memcheck, a memory error detector

==1760== Copyright (C) 2002-2010, and GNU GPL'd, by Julian Seward et al.

==1760== Using Valgrind-3.6.0.SVN-Debian and LibVEX; rerun with -h for
copyright info

==1760== Command: php /usr/local/src/phploc/phploc.php

==1760== 

==1760== Invalid read of size 4

==1760==at 0x92C021: _zend_is_inconsistent (zend_hash.c:54)

==1760==by 0x92EDAE: zend_hash_quick_find (zend_hash.c:929)

==1760==by 0xA49488: zend_fetch_var_address_helper_SPEC_CV_UNUSED
(zend_vm_execute.h:33194)

==1760==by 0xA49DEF: ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER
(zend_vm_execute.h:33294)

==1760==by 0x957F02: execute (zend_vm_execute.h:410)

==1760==by 0x91CD93: zend_execute_scripts (zend.c:1195)

==1760==by 0x89661E: php_execute_script (main.c:2341)

==1760==by 0xA57D89: main (php_cli.c:1254)

==1760==  Address 0x44 is not stack'd, malloc'd or (recently) free'd

==1760== 

==1760== 

==1760== Process terminating with default action of signal 11 (SIGSEGV)

==1760==  Access not within mapped region at address 0x44

==1760==at 0x92C021: _zend_is_inconsistent (zend_hash.c:54)

==1760==by 0x92EDAE: zend_hash_quick_find (zend_hash.c:929)

==1760==by 0xA49488: zend_fetch_var_address_helper_SPEC_CV_UNUSED
(zend_vm_execute.h:33194)

==1760==by 0xA49DEF: ZEND_FETCH_IS_SPEC_CV_UNUSED_HANDLER
(zend_vm_execute.h:33294)

==1760==by 0x957F02: execute (zend_vm_execute.h:410)

==1760==by 0x91CD93: zend_execute_scripts (zend.c:1195)

==1760==by 0x89661E: php_execute_script (main.c:2341)

==1760==by 0xA57D89: main (php_cli.c:1254)

==1760==  If you believe this happened as a result of a stack

==1760==  overflow in your program's main thread (unlikely but

==1760==  possible), you can try to increase the size of the

==1760==  main thread stack using the --main-stacksize= flag.

==1760==  The main thread stack size used in this run was 8388608.

==1760== 

==1760== HEAP SUMMARY:

==1760== in use at exit: 3,823,481 bytes in 18,002 blocks

==1760==   total heap usage: 34,509 allocs, 16,507 frees, 5,584,071 bytes
allocated

==1760== 

==1760== LEAK SUMMARY:

==1760==definitely lost: 0 bytes in 0 blocks

==1760==indirectly lost: 0 bytes in 0 blocks

==1760==  possibly lost: 0 bytes in 0 blocks

==1760==still reachable: 3,823,481 bytes in 18,002 blocks

==1760== suppressed: 0 bytes in 0 blocks

==1760== Reachable blocks (those to which a pointer was found) are not
shown.

==1760== To see them, rerun with: --leak-check=full --show-reachable=yes

==1760== 

==1760== For counts of detected and suppressed errors, rerun with: -v

==1760== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 4 from 4)

zsh: segmentation fault  USE_ZEND_ALLOC=0 valgrind --leak-check=full php 









s...@thinkpad ~ % gdb php

GNU gdb (GDB) 7.2-ubuntu

Copyright (C) 2010 Free Software Foundation, Inc.

License GPLv3+: GNU GPL version 3 or later


This is free software: you are free to change and redistribute it.

There is NO WARRANTY, to the extent permitted by law.  Type "show copying"

and "show warranty" for details.

This GDB was configured as "x86_64-linux-gnu".

For bug reporting instructions, please see:

...

Reading symbols from /usr/local/php-5.4/bin/php...done.

(gdb) r /usr/local/src/phploc/phploc.php

Starting program: /usr/local/php-5.4/bin/php
/usr/local/src/phploc/phploc.php

[Thread debugging using libthread_db enabled]



Program received signal SIGSEGV, Segmentation fault.

0x0092c021 in _zend_is_inconsistent (ht=0x0, file=0xf8d9e8
"/usr/local/src/php/src/php/php-src/trunk/Zend/zend_hash.c", line=929)

at /usr/local/src/php/src/php/php-src/trunk/Zend/zend_hash.c:54

54  if (ht->inconsistent==HT_OK) {

(gdb) bt

#0  0x0092c021 in _zend_is_inconsistent (ht=0x0, file=0xf8d9e8
"/usr/local/src/php/src/php/php-src/trunk/Zend/zend_hash.c", line=929)

at /usr/local/src/php/src/php/php-src/trunk/Zend/zend_hash.c:54

#1  0x0092edaf in zend_hash_quick_find (ht=0x0,
arKey=0x77ecc7e0 "color", nKeyLength=6, h=6953399188164,
pData=0x7fffbe80)

at /usr/local/src/php/src/php/php-src/trunk/Zend/zend_hash.c:929

#2  0x00a49489 in zend_fetch_

[PHP-BUG] Bug #53900 [NEW]: Reflection API shows wrong class name for namespaced type hints

2011-02-01 Thread sebast...@php.net
From: 
Operating system: Irrelevant
PHP version:  trunk-SVN-2011-02-01 (SVN)
Package:  Scripting Engine problem
Bug Type: Bug
Bug description:Reflection API shows wrong class name for namespaced type hints

Description:

When using namespaced classes as a type hint like in the test script
attached to this bug report, the ReflectionParameter object generated for
the parameter contains a fully-qualified class name for the type hinted
class where the name of the namespace is duplicated (see actual output).



This also causes ReflectionParameter::getClass() to fail as no
ReflectionClass object can be created for the invalid class name.

Test script:
---
getParameters() as $parameter) {

print $parameter;

}

?>

Expected result:

Parameter #0 [  ImageTransform\Image $image ]Parameter #1 [
 $width ]Parameter #2 [  $height ]

Actual result:
--
Parameter #0 [  ImageTransform\ImageTransform\Image $image
]Parameter #1 [  $width ]Parameter #2 [  $height ]

-- 
Edit bug report at http://bugs.php.net/bug.php?id=53900&edit=1
-- 
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=53900&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=53900&r=trysnapshot53
Try a snapshot (trunk):  
http://bugs.php.net/fix.php?id=53900&r=trysnapshottrunk
Fixed in SVN:
http://bugs.php.net/fix.php?id=53900&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=53900&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=53900&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=53900&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=53900&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=53900&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=53900&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=53900&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=53900&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=53900&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=53900&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=53900&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=53900&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=53900&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=53900&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=53900&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=53900&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=53900&r=mysqlcfg



[PHP-BUG] Req #55490 [NEW]: Allow instantiating objects without invoking the constructor

2011-08-23 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  Irrelevant
Package:  Reflection related
Bug Type: Feature/Change Request
Bug description:Allow instantiating objects without invoking the constructor

Description:

Libraries such as Doctrine 2 and PHPUnit_MockObject (ab)use the
unserialize() function (unserialize(sprintf('O:%d:"%s":0:{}',
strlen($name), $name))) to instantiate an object of a class without
invoking the constructor.

It would be nice if the Reflection API provided a clean API for this use
case that does not depend on implementation details of PHP's serializer.


-- 
Edit bug report at https://bugs.php.net/bug.php?id=55490&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=55490&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=55490&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=55490&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=55490&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=55490&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=55490&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=55490&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=55490&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=55490&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=55490&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=55490&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=55490&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=55490&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=55490&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=55490&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=55490&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=55490&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=55490&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=55490&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=55490&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=55490&r=mysqlcfg



Req #55490 [PATCH]: Allow instantiating objects without invoking the constructor

2011-08-25 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=55490&edit=1

 ID: 55490
 Patch added by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow instantiating objects without invoking the
 constructor
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264277
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264277


Previous Comments:

[2011-08-23 12:31:07] sebast...@php.net

Description:

Libraries such as Doctrine 2 and PHPUnit_MockObject (ab)use the unserialize() 
function (unserialize(sprintf('O:%d:"%s":0:{}', strlen($name), $name))) to 
instantiate an object of a class without invoking the constructor.

It would be nice if the Reflection API provided a clean API for this use case 
that does not depend on implementation details of PHP's serializer.







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=55490&edit=1


Req #55490 [PATCH]: Allow instantiating objects without invoking the constructor

2011-08-25 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=55490&edit=1

 ID: 55490
 Patch added by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow instantiating objects without invoking the
 constructor
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264428
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264428


Previous Comments:

[2011-08-25 09:24:37] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264277
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264277


[2011-08-23 12:31:07] sebast...@php.net

Description:

Libraries such as Doctrine 2 and PHPUnit_MockObject (ab)use the unserialize() 
function (unserialize(sprintf('O:%d:"%s":0:{}', strlen($name), $name))) to 
instantiate an object of a class without invoking the constructor.

It would be nice if the Reflection API provided a clean API for this use case 
that does not depend on implementation details of PHP's serializer.







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=55490&edit=1


Req #55490 [PATCH]: Allow instantiating objects without invoking the constructor

2011-08-25 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=55490&edit=1

 ID: 55490
 Patch added by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow instantiating objects without invoking the
 constructor
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314265167
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314265167


Previous Comments:

[2011-08-25 09:27:08] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264428
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264428


[2011-08-25 09:24:37] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264277
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264277

----
[2011-08-23 12:31:07] sebast...@php.net

Description:

Libraries such as Doctrine 2 and PHPUnit_MockObject (ab)use the unserialize() 
function (unserialize(sprintf('O:%d:"%s":0:{}', strlen($name), $name))) to 
instantiate an object of a class without invoking the constructor.

It would be nice if the Reflection API provided a clean API for this use case 
that does not depend on implementation details of PHP's serializer.







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=55490&edit=1


Req #55490 [PATCH]: Allow instantiating objects without invoking the constructor

2011-08-25 Thread sebast...@php.net
Edit report at https://bugs.php.net/bug.php?id=55490&edit=1

 ID: 55490
 Patch added by: sebast...@php.net
 Reported by:sebast...@php.net
 Summary:Allow instantiating objects without invoking the
 constructor
 Status: Open
 Type:   Feature/Change Request
 Package:Reflection related
 Operating System:   Irrelevant
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314278793
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314278793


Previous Comments:

[2011-08-25 09:39:27] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314265167
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314265167


[2011-08-25 09:27:08] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264428
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264428

----
[2011-08-25 09:24:37] sebast...@php.net

The following patch has been added/updated:

Patch Name: ReflectionClass_newInstanceWithoutConstructor
Revision:   1314264277
URL:
https://bugs.php.net/patch-display.php?bug=55490&patch=ReflectionClass_newInstanceWithoutConstructor&revision=1314264277

--------
[2011-08-23 12:31:07] sebast...@php.net

Description:

Libraries such as Doctrine 2 and PHPUnit_MockObject (ab)use the unserialize() 
function (unserialize(sprintf('O:%d:"%s":0:{}', strlen($name), $name))) to 
instantiate an object of a class without invoking the constructor.

It would be nice if the Reflection API provided a clean API for this use case 
that does not depend on implementation details of PHP's serializer.







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=55490&edit=1


[PHP-BUG] Bug #60140 [NEW]: ReflectionMethod::invoke*() does not work for pass-by-ref arguments

2011-10-26 Thread sebast...@php.net
From: sebastian
Operating system: Irrelevant
PHP version:  5.3SVN-2011-10-26 (SVN)
Package:  Reflection related
Bug Type: Bug
Bug description:ReflectionMethod::invoke*() does not work for pass-by-ref 
arguments

Description:

ReflectionMethod::invoke*() does not work for methods that expect
pass-by-reference arguments.

Test script:
---
invoke($object, $array);
?>

Actual result:
--
Warning: Parameter 1 to Foo::bar() expected to be a reference, value given
in /home/sb/test.php on line 13

Fatal error: Uncaught exception 'ReflectionException' with message
'Invocation of method Foo::bar() failed' in /home/sb/test.php:13
Stack trace:
#0 /home/sb/test.php(13): ReflectionMethod->invoke(Object(Foo), Array)
#1 {main}
  thrown in /home/sb/test.php on line 13


-- 
Edit bug report at https://bugs.php.net/bug.php?id=60140&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=60140&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=60140&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=60140&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=60140&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=60140&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=60140&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=60140&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=60140&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=60140&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=60140&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=60140&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=60140&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=60140&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=60140&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=60140&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=60140&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=60140&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=60140&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=60140&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=60140&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=60140&r=mysqlcfg