PHP upgrade causes SquirrelMail error reading new messages.

Technical Q&A involving operating systems, networking, software, and hardware issues.

Moderator: jasonb

Post Reply
User avatar
jasonb
Site Administrator
Posts: 105
Joined: Tue Apr 22, 2003 1:54 pm
Location: Toronto, Canada
Contact:

PHP upgrade causes SquirrelMail error reading new messages.

Post by jasonb »

After upgrading to the latest PHP, SquirrelMail 1.5.1 started showing "Message: preg_split() expects parameter 4 to be long, string given" at the bottom of each message.

This is fixed by modifying line 926 of functions/imap_messages.php.

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

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

(Change "NI" to "NO" and remove the single quotes around the parameter.)
Post Reply