php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #32894 System defined object exception stack trace errors
Submitted: 2005-04-29 21:37 UTC Modified: 2005-07-08 21:55 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: scottmattocks@php.net Assigned:
Status: Closed Package: Class/Object related
PHP Version: 5CVS-2005-06-19 OS: *
Private report: No CVE-ID: None
 [2005-04-29 21:37 UTC] scottmattocks@php.net
Description:
------------
If an exception is thrown by a system class (not user defined), the stack trace is not correct. At least one level is missing and parameters from the method which threw the exception are displayed as having been passed to the function/method which called the method that threw the exception.

Reproduce code:
---------------
http://crisscott.com/php_bug.txt

Expected result:
----------------
Warning: GtkMenuItem::__construct() requires exactly 0 arguments, 1 given in /home/scott/php-gtk2_test.php on line 14
could not construct GtkMenuItem object
#0 /home/scott/php-gtk2_test.php(14): GtkMenuItem('GtkMenuItem')
#1 /home/scott/php-gtk2_test.php(35): func0('func0')
#2 {main}
TestClass __construct problem.
#0 /home/scott/php-gtk2_test.php(28): TestClass->__construct('TestClass')
#1 /home/scott/php-gtk2_test.php(35): func0('func0')
#2 {main} 

Actual result:
--------------
Warning: GtkMenuItem::__construct() requires exactly 0 arguments, 1 given in /home/scott/php-gtk2_test.php on line 14
could not construct GtkMenuItem object
#0 /home/scott/php-gtk2_test.php(28): func0('GtkMenuItem')
#1 {main}
TestClass __construct problem.
#0 /home/scott/php-gtk2_test.php(28): TestClass->__construct('TestClass')
#1 /home/scott/php-gtk2_test.php(35): func0('func0')
#2 {main} 

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-04-30 04:31 UTC] sniper@php.net
Provide a test script which does NOT rely on PHP-GTK2 or
any other external extension.


 [2005-05-02 17:41 UTC] scottmattocks@php.net
I commented out the PHP-GTK 2 code and uncommented the SimpleXML example. The same URL can be used to see the code sample: http://crisscott.com/php_bug.txt
 [2005-07-08 21:55 UTC] tony2001@php.net
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
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.

Fixed along with #28377 & friends.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat May 18 16:01:36 2024 UTC