ID: 33039 Updated by: [EMAIL PROTECTED] Reported By: mpb dot mail at gmail dot com -Status: Open +Status: Feedback Bug Type: IMAP related Operating System: Gentoo Linux PHP Version: 5.0.3 New Comment:
Please try using this CVS snapshot: http://snaps.php.net/php5-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.0-win32-latest.zip Previous Comments: ------------------------------------------------------------------------ [2005-05-16 08:35:15] mpb dot mail at gmail dot com Description: ------------ If you imap_open an empty pop mailbox, a "Mailbox is empty (errflg=1)" notice will be printed during PHP's "shutdown" or "cleanup" phase after your script has finished running (assuming E_NOTICE is set, of course). As there is nothing wrong with having an empty mailbox, I believe that PHP should not print this notice. I suspect that PHP is misinterpreting a return code from the IMAP library, or is making an unnecessary call to the IMAP library. It is also possible that the IMAP library is buggy and should not be returning an errflg=1 (whatever that means). If, in the reproduce code, you uncomment the final ini_set then the notice will not be printed (as E_NOTICE is no longer set during PHP's shutdown). If you are unable to reproduce this problem with the empty POP mailbox of your choice, let me know and I will set up a POP mailbox for you to test against. See also bug 7207. Reproduce code: --------------- ini_set ('error_reporting', E_ALL); $imap = imap_open ( '{host.com:110/pop/novalidate-cert}INBOX', 'user', 'password' ); trigger_error ('test notice'); sleep (5); // ini_set ('error_reporting', E_ALL ^ E_NOTICE); Expected result: ---------------- Notice: test notice in /root/pinstall/local/vl0/test.php on line 8 Actual result: -------------- Notice: test notice in /root/pinstall/local/vl0/test.php on line 8 Notice: Unknown: Mailbox is empty (errflg=1) in Unknown on line 0 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=33039&edit=1
