Re: Getting error: strpos() Offset not contained in string in imap_messages.php on line 542

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 7, 2010 at 12:39 PM, Chris Kimpton <chris@xxxxxxxxxxx> wrote:
> Hi,
>
> I subscribe to the squirrelmail-users mailing list.
>   [ X ]  True - No need to CC me when replying
>   [ ]  False - Please CC me when replying
>
> This bug occurs when I ...
>   ... try to do/view/use ....  when logging in, intermittently...
>
> The description of the bug:
>
> I have just upgraded from 1.4.15 to 1.4.19 (due to ubuntu upgrade to 9).
>
> I am now getting occasional errors like this when logging in:
>
> strpos() [function.strpos]: Offset not contained in string in
> /usr/share/squirrelmail/functions/imap_messages.php on line 542
>
> A reload usually fixes it - works the second time.
>
> Does this ring a bell - have I got PHP/courier misconfigured perhaps... ?

It is a problem with something in your filters plugin configuration/operation.

You can print out the string that is being parsed, although it might
be messy.  BEFORE line 542, you can add something like:

echo "READ IS: "; var_dump($read); echo "<hr />";

> Perhaps relevant is that I have 2 separate browser sessions open at the
> same... perhaps the issue is a clash between then, I have load of filters
> and so the INBOX maybe changing due to one reloading and applying
> filters/moving messages -which the other session is also trying to do...
>
>
> I can reproduce the bug by:
> Occurs intermittently, mainly seen when loggin on.
>
> (Optional) I got bored and found the bug occurs in:
> function parseFetch(&$aResponse, $aMessageList = array()) {
>     for($j=0, $iCnt = count($aResponse);$j<$iCnt; ++$j) {
>         $aMsg = array();
>
>         $read = implode('', $aResponse[$j]);
>         // Clear up some memory
>         unset($aResponse[$j]);
>
>         /*
>                         *<space>#id<space>FETCH<space>(....
>          */
>
>         $i_space = strpos($read,' ', 2);  // THIS IS LINE 542...
>
>
>
>
> ----------------------------------------------
>
> My browser information:
>   Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-US) AppleWebKit/533.2
> (KHTML, like Gecko) Chrome/5.0.342.9 Safari/533.2
>
> My web server information:
>   PHP Version 5.2.10-2ubuntu6.4
>   PHP Extensions (List)
>     * 0 = date
>     * 1 = libxml
>     * 2 = openssl
>     * 3 = pcre
>     * 4 = zlib
>     * 5 = bcmath
>     * 6 = bz2
>     * 7 = calendar
>     * 8 = ctype
>     * 9 = dba
>     * 10 = dom
>     * 11 = session
>     * 12 = filter
>     * 13 = ftp
>     * 14 = gettext
>     * 15 = hash
>     * 16 = iconv
>     * 17 = json
>     * 18 = mbstring
>     * 19 = mime_magic
>     * 20 = posix
>     * 21 = Reflection
>     * 22 = standard
>     * 23 = shmop
>     * 24 = SimpleXML
>     * 25 = soap
>     * 26 = sockets
>     * 27 = SPL
>     * 28 = exif
>     * 29 = sysvmsg
>     * 30 = sysvsem
>     * 31 = sysvshm
>     * 32 = tokenizer
>     * 33 = wddx
>     * 34 = xml
>     * 35 = xmlreader
>     * 36 = xmlwriter
>     * 37 = zip
>     * 38 = apache2handler
>     * 39 = mhash
>     * 40 = mysql
>     * 41 = mysqli
>     * 42 = PDO
>     * 43 = pdo_mysql
>
> SquirrelMail-specific information:
>   Version:  1.4.19
>   Plugins (List)
>     * 0 = info
>     * 1 = squirrelspell
>     * 2 = spamcop
>     * 3 = filters
>     * 4 = fortune
>     * 5 = translate
>     * 6 = mail_fetch
>     * 7 = administrator
>     * 8 = newmail
>     * 9 = listcommands
>     * 10 = delete_move_next
>     * 11 = bug_report
>     * 12 = abook_take
>     * 13 = message_details
>     * 14 = view_as_html
>
> My IMAP server information:
>   Server type:  courier
>   Server info:  * OK [HIDDEN] IMAP4rev1 UIDPLUS CHILDREN NAMESPACE
> THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION
> Courier-IMAP ready. Copyright 1998-2008 Double Precision, Inc. See COPYING
> for distribution information.
>   Capabilities:  IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT
> THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION
>
>
>
> Thanks in advance for any tips/advice.
>
> Regards,
> Chris
>
> ------------------------------------------------------------------------------
>
>
> -----
> squirrelmail-users mailing list
> Posting guidelines: http://squirrelmail.org/postingguidelines
> List address: squirrelmail-users@xxxxxxxxxxxxxxxxxxxxx
> List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
> List info (subscribe/unsubscribe/change options):
> https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
>



-- 
Paul Lesniewski
SquirrelMail Team
Please support Open Source Software by donating to SquirrelMail!
http://squirrelmail.org/donate_paul_lesniewski.php

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

-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: squirrelmail-users@xxxxxxxxxxxxxxxxxxxxx
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users


[Index of Archives]     [Video For Linux]     [Yosemite News]     [Yosemite Photos]     [gtk]     [KDE]     [Cyrus SASL]     [Gimp on Windows]     [Steve's Art]     [Webcams]

  Powered by Linux