#33349 [NEW]: imap_fetchstructure hangs on some mails
| From: | benjamin dot malynovytch at libertic dot fr | Date: | Wed, 15 Jun 2005 09:36:31 +0000 |
| Subject: | #33349 [NEW]: imap_fetchstructure hangs on some mails | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-80364@lists.php.net to get a copy of this message | ||
From: benjamin dot malynovytch at libertic dot fr
Operating system: Linux (Mandrake 9.2)
PHP version: 5.0.4
PHP Bug Type: IMAP related
Bug description: imap_fetchstructure hangs on some mails
Description:
------------
Calling imap_fetchstructure() on certain multi-part messages causes an
indefinite hang (function never returns).
Versions:
Tried: PHP-5.0.3, PHP-5.0.4, PHP-5.0.5-dev
c-client: imap-2004d
Apache: httpd-2.0.53
I gave a look at other related bugs, and checkd that que imap link was
still up when the function was called. I also tried to place a timer
between two function calls.
Nothing worked, the link is still up when que function hangs.
Reproduce code:
---------------
<?php
$pop_user = "someuser";
$pop_pass = "somepassword";
$pop_host = "somehost.somewhere.com";
$mbox_path = "/path/to/failedmsg.1";
$pop_conn_string = "\{$pop_host:143/imap}$mbox_path";
$pop_conn = imap_open($pop_conn_string, $pop_user, $pop_pass);
// Assuming message-of-death is first one in the mbox
$mimeobj = imap_fetchstructure($pop_conn, 1);
// Never gets here...
imap_close($pop_conn);
?>
Expected result:
----------------
imap_fetchstructure() should quickly return the structure of the
message.
Actual result:
--------------
The function never returns on most mails, and page loading stops.
--
Edit bug report at http://bugs.php.net/?id=33349&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=33349&r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=33349&r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=33349&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=33349&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=33349&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=33349&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=33349&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=33349&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=33349&r=support
Expected behavior: http://bugs.php.net/fix.php?id=33349&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=33349&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=33349&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=33349&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=33349&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=33349&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=33349&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=33349&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=33349&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=33349&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=33349&r=mysqlcfg