Roundcube Community Forum

News and Announcements => General Discussion => Topic started by: paritycheck on January 19, 2010, 09:22:54 AM

Title: RCmail not working with my providor the ReadLine func goes in a never ending loop!!!
Post by: paritycheck on January 19, 2010, 09:22:54 AM
Hi guys - I seem to have a problem with rcmail here. It was working fine with my providor when all of a sudden somethings gone wrong. To start with its not able to login to the providor to begin with - instead it dies out.

I tried to trace the issue and found that the iil_C_FetchHeaders function makes a call to the iil_ReadLine function in the lib\imap.inc file and at that point the loop goes on endlessly. I traced even the iil_ReadLine function and saw that theres a small loop there which reads a line from the connection however its constantly reading in a false value and the false value seems to be never ending.

I checked with another mail providor and it works fine. I don't know whats wrong here - please do help....we haven't made any change to the configuration at all....it was working before but its dead now?
Title: RCmail not working with my providor the ReadLine func goes in a never ending loop!!!
Post by: SKaero on January 19, 2010, 10:34:07 AM
Whats the error in the error log, also what is the imap server log look like when you are trying to login.
Title: RCmail not working with my providor the ReadLine func goes in a never ending loop!!!
Post by: paritycheck on January 20, 2010, 12:23:38 AM
Well the error log reports a timeout - its logging in I mean authentication is working fine, its only when its fetching headers that something goes wrong. The ReadLine function:
function iil_ReadLine($fp, $size=1024) {

$line = '';

if (!$fp) {
    return $line;
}
   
if (!$size) {
$size = 1024;
}
   
do {
    $buffer = fgets($fp, $size);

_log('buffer');

    if ($buffer === false) {
        break;
    }
$line .= $buffer;
} while ($buffer[strlen($buffer)-1] != "\n");

return $line;
}

looks like that I try to trace the fp and buffer variables and all I get prior to the timeout are a looooong continuity of just NULL and false values respectively. Is this a providor issue? There are lot of mails in the mailbox but that was never an issue before so whats going on now?
Title: RCmail not working with my providor the ReadLine func goes in a never ending loop!!!
Post by: alec on January 20, 2010, 02:14:41 AM
Quote from: paritycheck;24689looks like that I try to trace the fp and buffer variables and all I get prior to the timeout are a looooong continuity of just NULL and false values respectively.

Enable imap_debug in Roundcube and check in logs/imap what happen before.