Browse Source

Tweak the LSUB INBOX regexp to allow for only 1 space between LSUB and
the mailbox name.

Thijs Kinkhorst 21 years ago
parent
commit
e424ef3bc1
1 changed files with 1 additions and 1 deletions
  1. 1 1
      functions/imap_mailbox.php

+ 1 - 1
functions/imap_mailbox.php

@@ -812,7 +812,7 @@ function sqimap_mailbox_tree($imap_stream) {
         $has_inbox = false;
         $has_inbox = false;
 
 
         for ($i = 0, $cnt = count($lsub_ary); $i < $cnt; $i++) {
         for ($i = 0, $cnt = count($lsub_ary); $i < $cnt; $i++) {
-            if (preg_match("/^\*\s+LSUB\s+(.*)\s\"?INBOX\"?[^(\/\.)].*$/i",$lsub_ary[$i])) {
+            if (preg_match("/^\*\s+LSUB.*\s\"?INBOX\"?[^(\/\.)].*$/i",$lsub_ary[$i])) {
 	        $lsub_ary[$i] = strtoupper($lsub_ary[$i]);
 	        $lsub_ary[$i] = strtoupper($lsub_ary[$i]);
                 $has_inbox = true;
                 $has_inbox = true;
                 break;
                 break;