Empty $mailbox causes sent append to break.
authorjangliss <jangliss@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 14 Apr 2003 18:21:44 +0000 (18:21 +0000)
committerjangliss <jangliss@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 14 Apr 2003 18:21:44 +0000 (18:21 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@4767 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/imap_mailbox.php

index f13bae9..bb46e6f 100755 (executable)
@@ -188,7 +188,7 @@ function sqimap_mailbox_expunge ($imap_stream, $mailbox, $handle_errors = true,
 
 /* Checks whether or not the specified mailbox exists */
 function sqimap_mailbox_exists ($imap_stream, $mailbox) {
-    if (!isset($mailbox)) {
+    if (!isset($mailbox) || empty($mailbox)) {
         return false;
     }
     $mbx = sqimap_run_command($imap_stream, "LIST \"\" \"$mailbox\"",