Author Topic: RCmail not working with my providor the ReadLine func goes in a never ending loop!!!  (Read 3282 times)

Offline paritycheck

  • Jr. Member
  • **
  • Posts: 36
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?

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,882
    • SKaero - Custom Roundcube development
Whats the error in the error log, also what is the imap server log look like when you are trying to login.

Offline paritycheck

  • Jr. Member
  • **
  • Posts: 36
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:
Code: [Select]
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?

Offline alec

  • Hero Member
  • *****
  • Posts: 1,365
Quote from: paritycheck;24689

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.


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