From 7342d7ef8c277c32bb161eeb585d98099f2b04fe Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Fri, 28 Nov 2008 03:53:48 -0500
Subject: [PATCH] - re-fix r2095

---
 index.php            |    2 +-
 program/lib/imap.inc |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/index.php b/index.php
index 8b31f99..d4fc543 100644
--- a/index.php
+++ b/index.php
@@ -100,7 +100,7 @@
     $OUTPUT->redirect();
   }
   else {
-    $OUTPUT->show_message($IMAP->error_code == 0 ? 'loginfailed' : 'imaperror', 'warning');
+    $OUTPUT->show_message($IMAP->error_code < -1 ? 'imaperror' : 'loginfailed', 'warning');
     $RCMAIL->kill_session();
   }
 }
diff --git a/program/lib/imap.inc b/program/lib/imap.inc
index f269c21..6fb60e9 100644
--- a/program/lib/imap.inc
+++ b/program/lib/imap.inc
@@ -586,7 +586,7 @@
 	$conn->fp = fsockopen($host, $ICL_PORT, $errno, $errstr, 10);
 	if (!$conn->fp) {
     		$iil_error = "Could not connect to $host at port $ICL_PORT: $errstr";
-    		$iil_errornum = -1;
+    		$iil_errornum = -2;
 		return false;
 	}
 

--
Gitblit v1.9.1