php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18392 imap functions stop working correctly when curl compiled in
Submitted: 2002-07-17 09:49 UTC Modified: 2002-07-18 10:30 UTC
From: manu@php.net Assigned:
Status: Closed Package: IMAP related
PHP Version: 4.2.1 OS: sun solaris 2.6
Private report: No CVE-ID: None
 [2002-07-17 09:49 UTC] manu@php.net
The following script is working just as expected when php is compiled --with-imap : It displays "conn ok" + a number.
But when php is compiled --with-curl as well, the script displays "conn ok" + "empty".
There's no error nor warning.

Config :

./configure  --enable-ucd-snmp-hack --with-apache=../apache_1.3.26 --enable-bcmath --enable-calendar --enable-ftp --with-gd=/usr/local/gd1.2 --with-imap=../imap-2001a --with-mysql=/usr/local/mysql --with-snmp --enable-inline-optimization --enable-memory-limit --with-zlib --with-curl

The librairies used are :

imap-2001a : make gso
curl-7.9.8 : configure --with-ssl

--------------

<?php
        $server="imap.server.net";
        if ( $mbox = imap_open ("{".$server.":143}INBOX", "email@server.net", "pass")) {
                echo "conn ok<br>";

                $headers = imap_headers ($mbox);
                if ($headers == false){
                        echo "Empty<br>";
                } else{
                        $size=sizeof($headers);
                        echo "$size";
                }
                imap_close($mbox);
        }
?>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-07-17 11:34 UTC] sniper@php.net
First try this snapshot:

http://snaps.php.net/php4-latest.tar.gz

You're sure your c-client is not linked with SSL too?
And you don't (check it!) have any c-client headers installed anywhere in your system?

Also, try adding 'echo imap_last_error()' after the imap_open() line.

 [2002-07-18 03:43 UTC] manu@php.net
I should I've mentionned that I tried php4-STABLE-200207170300. No success.

echo imap_last_error() doesn't display anything.

I'll check if there's not some old c-client headers.

And I tought that the c-client wasn't compiled with ssl ( compiling php --with-imap-ssl complained...)
But  nm -A c-client.a | grep -i ssl shows me that "ssl_server_init" is there.
So regarding the issues involved with curl + ssl initialization in the past, it may well be the pb.
I'll try and report.
Thanks
 [2002-07-18 04:44 UTC] sniper@php.net
Try with that exact package I posted url to..NOT the 'STABLE' one.

Also, what was in config.log when you used --with-imap-ssl and it failed?

 [2002-07-18 10:30 UTC] manu@php.net
Ok. After >100 compilations and some waste of bandwith from snaps.php.net, the issue is resolved.
As you hinted, it was old c-client headers.
I wonder how it has worked so far ? (before I need curl).
what's odd is that they were picked in /usr/local/include despite I ./configure --with-imap=../imap-2001a...
Thanks.

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 22:01:28 2024 UTC