ID:               35626
 User updated by:  elg at op dot pl
 Reported By:      elg at op dot pl
 Status:           Bogus
 Bug Type:         Compile Warning
 Operating System: windows
 PHP Version:      5.1.1
 New Comment:

If I've miss undersend your sugestion then I'm truelly sory but I know
that my exceptions handler makes nothing with cought exception and I
dont think this is the problem. Even if there would be no exception
handler or if it would write this exception information into a file it
should not display this worning (in fact it is not showing any warnings
when I am not throwing exceptions in error handler). Sory for taking
your time with this problem but I have searched many forums for help
and there was nobody that could help me :(


Previous Comments:
------------------------------------------------------------------------

[2005-12-10 22:59:46] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

You're using exception handler that apparently makes exceptions to
disappear. 

------------------------------------------------------------------------

[2005-12-10 22:49:03] elg at op dot pl

Description:
------------
I wanted to convert errors to exceptions by writing an error handler
that throws them as exceptions.
Then I wanted to check if it works so I tried to include a non 
existing file (info.txt)

Reproduce code:
---------------
<?php
function exceptionHandler($exc){
echo ':)';
}
function ErrorsToExceptions($severity, $message) {
        throw new ErrorException($message,0, $severity);
        }
        set_exception_handler('exceptionHandler');
        set_error_handler('ErrorsToExceptions');
include'dupa.txt';
?>

Expected result:
----------------
:)

Actual result:
--------------
Warning: main() [function.include]: Failed opening 'info.txt' for
inclusion (include_path='.;C:\php5\pear') in
E:\usr\\www\index.php on line 8
:)


------------------------------------------------------------------------


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

Reply via email to