Edit report at https://pear.php.net/bugs/bug.php?id=14275&edit=1
ID: 14275
Updated by: [email protected]
Reported By: ben dot [email protected]
Summary: getHeaders breaks using default values
-Status: Open
+Status: Closed
Type: Bug
Package: Mail_IMAP
Operating System: linux
Package Version: 1.1.0RC2
PHP Version: 5.2.6
-Assigned To:
+Assigned To: richy
Roadmap Versions:
New Comment:
-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: richy
Bug fixed in PHP five years ago.
Previous Comments:
------------------------------------------------------------------------
[2008-07-02 00:29:49] brettjamin
Description:
------------
Using the default values for $from_length, and $subject_length in the
function getHeaders breaks. This is due to this php bug:
http://bugs.php.net/bug.php?id=44613. Changing the default values for
these variables to 1023 solves this problem
Test script:
---------------
$imapObject =& new IMAP();
$imapObject->connect(
imaps://username:[email protected]:993/INBOX#novalidate-cert )
$mid = 37
$pid = $imapObject->getDefaultPid( $mid );
$imapObject->getHeaders( $mid, $pid);
Expected result:
----------------
$imapObject->headers array should have message header information
Actual result:
--------------
Returns false and does not fill out header array. Also sets these
warnings:
-imap_headerinfo() [<a
href='function.imap-headerinfo'>function.imap-headerinfo</a>]: From
length has to be between 1 and 1024
-Mail_IMAP::getHeaders: Unable to retrieve header object, invalid part
id: 1
------------------------------------------------------------------------