Blank right pane, Build 14995, Debian 11, PHP 7.4.33
"Dave Anderson" <[email protected]> Thu, 23 Nov 2023 23:16:42 -0800
| Newsgroups | gmane.mail.squirrelmail.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello,
Long time user of Squirrelmail. I can't live without it!
Upgrade from Squirrelmail 1.5.2 build 14986 to 14998 resulted in a blank right pane. Browser
developer tools console indicated an Internal server error 500 on file /src/right_main.php. I
could not debug the problem using /var/log/apache2/error.log since no errors were reported. I
tried configuring PHP to display errors but no luck.
My configuration:
SquirrelMail version 1.5.2 [SVN]
svn "Checked out revision 14998"
External email server - dnchosting.com
Squirrelmail installed on Debian 11 droplet, up to date
Server version: Apache/2.4.56 (Debian)
PHP 7.4.33
Accessed from Windows 10 with latest Firefox browser
Troubleshooting:
Used diff to find all file differences between working email client files and failing email client
files. Copied working client files one at a time to the failing client directory until
Squirrelmail displayed the right pane normally.
Here's the diff causing the error:
diff -bur squirrelmail/functions/imap_messages.php squirrelmail-svn/functions/imap_messages.php
--- squirrelmail/functions/imap_messages.php 2023-01-02 18:11:29.000000000 -0800
+++ squirrelmail-svn/functions/imap_messages.php 2023-11-23 17:00:09.868665851 -0800
@@ -8,7 +8,7 @@
*
* @copyright 1999-2023 The SquirrelMail Project Team
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @version $Id: imap_messages.php 14986 2023-01-03 02:11:29Z pdontthink $
+ * @version $Id: imap_messages.php 14995 2023-08-24 22:06:59Z pdontthink $
* @package squirrelmail
* @subpackage imap
*/
@@ -117,7 +117,7 @@
// some broken IMAP servers do not return UID elements on UID STORE
// if this is the case, then we need to do a UID FETCH
if (!empty($parseFetchResults)
- && !isset(reset($parseFetchResults)['UID'])) {
+ && !isset($parseFetchResults)['UID']) {
$aResponse = sqimap_run_command_list($imap_stream, "FETCH $msgs_id (FLAGS)",
$handle_errors, $response, $message, TRUE);
$parseFetchResults = parseFetch($aResponse,$aMessageList);
}
Further troubleshooting found that removing the "reset" command on line 120 caused the error. When
I inserted it back the error was gone. I'm at a loss as to why this is the case since the pointer
seems like it should be at the start of the array since it seems nothing has moved it forward. I'm
not sure what the reason for this error is but I wouldn't mind understanding this error more.
Maybe when an array is created the pointer is left at the end??? Maybe this could be PHP
misbehaving, I don't know.
Sorry if this report is not properly submitted or not clear.
Thanks,
Dave
-----
squirrelmail-devel mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [email protected]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.devel
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-devel