Typological Error in Squirrelmail 1.4.0

If you have installed Squirrelmail as your webmail application, have you ever seen error messages of your Squirrelmail like this?
Warning: preg_split() expects parameter 4 to be long, string given in /usr/local/www/squirrelmail/functions/imap_messages.php on line 806

Warning: Invalid argument supplied for foreach() in /usr/local/www/squirrelmail/functions/mime.php on line 53

I found this annoying bug when I was replying an e-mail from my friend. For your information, I have installed Squirrelmail version 1.4.0 in my own server. Actually it is not only the core application of Squirrelmail itself, but also containing the enchanting theme of Squirrelmail which I got from my friend (but he is different from my friend whom I have mentioned before :P).

Actually, it does not have any effect on e-mail composition. The message can be sent and delivered successfully, but those error messages are so annoying. So, I searched the bug fix via Google, and then I found the solution easily. Gosh! It is just a typological error. Here is the solution:

Just open the file which is first mentioned in the error message, and go to the following line (806). Replace this line:

$flags = preg_split('/ /', $regs[1],-1,'PREG_SPLIT_NI_EMPTY');

with

$flags = preg_split('/ /', $regs[1],-1,PREG_SPLIT_NO_EMPTY);

Obviously, it is just a typological error. Well, see you again in my next post then :D.

-KnightDNA-
blog comments powered by Disqus