|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #33967 misuse of Exception constructor doesn't display errorfile
Submitted: 2005-08-02 15:34 UTC Modified: 2005-08-02 18:32 UTC
From: benjamin at schulz dot name Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 5.1.0b3 OS: linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: benjamin at schulz dot name
New email:
PHP Version: OS:


 [2005-08-02 15:34 UTC] benjamin at schulz dot name
If the Exception constructor or a child class gets an object as argument the errormessage doesn't contain a file or line what makes it hard to track down because in <5.1 or even <= 5.1.0b2 (not sure) it was possible to use different prototypes in Exception children

Reproduce code:
throw new Exception(new stdClass);

Actual result:
Fatal error: Wrong parameter count for exception([string $exception [, long $code ]]) in Unknown on line 0


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-08-02 18:32 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-2024 The PHP Group
All rights reserved.
Last updated: Sun Jul 21 01:01:28 2024 UTC