From cf797fb97ed3ae4d65886016b831cdd3437ab3ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Toni=20F=C3=B6rster?= Date: Tue, 26 Aug 2014 17:08:46 +0200 Subject: [PATCH] Limit the number of maximum connect attempts to 1 http://php.net/manual/en/function.imap-open.php --- lib/imap.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/imap.php b/lib/imap.php index ae1ef67..3ccebf0 100644 --- a/lib/imap.php +++ b/lib/imap.php @@ -42,7 +42,7 @@ class OC_User_IMAP extends \OCA\user_external\Base { OCP\Util::writeLog('user_external', 'ERROR: PHP imap extension is not installed', OCP\Util::ERROR); return false; } - $mbox = @imap_open($this->mailbox, $uid, $password, OP_HALFOPEN); + $mbox = @imap_open($this->mailbox, $uid, $password, OP_HALFOPEN, 1); imap_errors(); imap_alerts(); if($mbox !== FALSE) {