Report new bug | New search | Development Roadmap Status: Open | Feedback | All

Bug #3311 incorrect return values
Submitted: 2005-01-27 12:56 UTC
From: rkwtavdw at puk dot ac dot za Assigned: danielc
Status: Closed Package: Documentation
PHP Version: 4.3.10 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2005-01-27 12:56 UTC] rkwtavdw at puk dot ac dot za
Description: ------------ The Net_POP3::login($username,$password) method API claims that it returns a boolean (stating whether the login was succesful or not), but I found it returned an Object on failure.

Comments

 [2005-02-24 16:44 UTC] mj
According to the sourcecode of Net_POP3::login() only boolean values are returned. Can you provide us example code with which you can reproduce the bug?
 [2005-08-25 13:41 UTC] matakagi at osk2 dot 3web dot ne dot jp
Hi, I reproduced the bug. try it. Actually, the sourcecode of Net_POP3::login() returns PEAR_Error (See: line 256 and line 264 of POP3.php). <?php require_once("Net/POP3.php"); $pop3 = new Net_POP3; $res = $pop3->connect('your.pop3.server'); $res = $pop3->login('your_account', 'wrong_password'); if (PEAR::isError($res)) { echo 'Net_POP3::login() returned PEAR_Error!'; } else { echo 'This Bug report is BOGUS!'; } ?>
 [2005-10-23 17:26 UTC] danielc
Fixed in CVS.