From: jangliss Date: Mon, 18 Nov 2002 06:15:06 +0000 (+0000) Subject: Added port check to make sure it is set otherwise this breaks X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=commitdiff_plain;h=e4cec78812dc681ca4dcab2cc375af0da967dce6 Added port check to make sure it is set otherwise this breaks git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@4170 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/plugins/mail_fetch/class.POP3.php b/plugins/mail_fetch/class.POP3.php index e4b78946..dcb9e1b4 100644 --- a/plugins/mail_fetch/class.POP3.php +++ b/plugins/mail_fetch/class.POP3.php @@ -71,7 +71,8 @@ class POP3 { // port defaults to 110. Returns true on success, false on fail // If MAILSERVER is set, override $server with it's value - + + if (!isset($port) || !$port) {$port = 110;} if(!empty($this->MAILSERVER)) $server = $this->MAILSERVER; @@ -82,7 +83,7 @@ class POP3 { } $fp = fsockopen("$server", $port, $errno, $errstr); - + echo 'Server: ' . $server . '
Port: ' . $port; if(!$fp) { $this->ERROR = _("POP3 connect:") . ' ' . _("Error ") . "[$errno] [$errstr]"; unset($this->FP);