Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.1.4

Bug #16819 IMAPProtocol::cmdStatus fails on error
Submitted: 2009-11-22 09:15 UTC
From: samwilson Assigned: doconnor
Status: Closed Package: Net_IMAP (version 1.1.0)
PHP Version: 5.2.5 OS: MacOS
Roadmaps: (Not assigned)    
Subscription  


 [2009-11-22 09:15 UTC] samwilson (Sam Wilson)
Description: ------------ The return value of $this->_genericCommand needs to be checked before it is used as an array (it might be a PEAR_Error). Test script: --------------- require_once 'Net/IMAP.php'; $imap = new Net_IMAP('mail.example.org'); $login = $imap->login('username', 'password'); $imap->numMsg(); Expected result: ---------------- [Nothing] Actual result: -------------- Fatal error: Cannot use object of type PEAR_Error as array in /home/user/pear/PEAR/Net/IMAPProtocol.php on line 1038

Comments

 [2009-11-22 09:17 UTC] samwilson (Sam Wilson)
 [2012-01-02 04:38 UTC] doconnor (Daniel O'Connor)
Thanks for the patch Sam. It's been a while since you uploaded it, and no reply - so I'm marking the package unmaintained.
 [2012-01-02 07:25 UTC] doconnor (Daniel O'Connor)
-Status: Open +Status: Closed -Assigned To: +Assigned To: doconnor
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.