This commit is contained in:
Marcus Bointon 2020-08-05 10:34:30 +02:00
parent e8a7364733
commit e7acd3d92f
No known key found for this signature in database
GPG Key ID: DE31CD6EB646AA24
1 changed files with 7 additions and 1 deletions

View File

@ -899,6 +899,7 @@ class PHPMailer
switch ($this->Debugoutput) {
case 'error_log':
//Don't output, just log
/** @noinspection ForgottenDebugOutputInspection */
error_log($str);
break;
case 'html':
@ -2002,7 +2003,12 @@ class PHPMailer
}
$host = $hostinfo[2];
$port = $this->Port;
if (array_key_exists(3, $hostinfo) && is_numeric($hostinfo[3]) && $hostinfo[3] > 0 && $hostinfo[3] < 65536) {
if (
array_key_exists(3, $hostinfo) &&
is_numeric($hostinfo[3]) &&
$hostinfo[3] > 0 &&
$hostinfo[3] < 65536
) {
$port = (int) $hostinfo[3];
}
if ($this->smtp->connect($prefix . $host, $port, $this->Timeout, $options)) {