|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #44487 call_user_method_array issues a warning when throwing an exception
Submitted: 2008-03-20 00:22 UTC Modified: 2008-03-20 01:07 UTC
From: Assigned: dsp
Status: Closed Package: Class/Object related
PHP Version: 5.2.6RC2 OS: Linux
Private report: No CVE-ID:
 [2008-03-20 00:22 UTC]
call_user_method_array issues a "cannot call method foo()" warning when  an exception is thrown.

Reproduce code:
class Foo
        public function bar()
                throw new Exception();

        public function test()
                call_user_func_array(array($this, 'bar'), array());

try {
        $bar = new Foo();
        call_user_method_array('test', $bar, array()) ;

} catch (Exception $e) {

Expected result:
no output

Actual result:
Warning: call_user_method_array(): Unable to call test() in /path/to/call.php on line 17


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2008-03-20 01:07 UTC]
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2015 The PHP Group
All rights reserved.
Last updated: Mon Nov 30 18:01:32 2015 UTC