Another initialization thing fixed
[squirrelmail.git] / functions / imap_search.php
index de6bf6d8e324dc70c3d8d80eeffcd3e8b42aa139..a9cda0660a1fc32bf1920dac85f614a88db5a80b 100644 (file)
@@ -39,8 +39,10 @@ function sqimap_search($imapConnection,$search_where,$search_what,$mailbox,$colo
       #Check to see if a SEARCH Responce was recived
       if (substr($readin[$c],0,9) == "* SEARCH ")
          $messagelist = explode(" ",substr($readin[$c],9));
-      else
+      else if (isset($errors))
          $errors = $errors.$readin[$c];
+      else
+         $errors = $readin[$c];
       $c++;
    }