mirror of
https://github.com/PHPMailer/PHPMailer.git
synced 2024-09-20 01:52:15 +02:00
Trap low-level SMTP errors, see #1012
This commit is contained in:
parent
863e531de8
commit
799ff351ca
@ -45,6 +45,7 @@ This is a major update that breaks backwards compatibility.
|
||||
* Simplification of address validation - now uses PHP's `FILTER_VALIDATE_EMAIL` pattern by default, retains advanced options
|
||||
* `Debugoutput` can accept a PSR-3 logger instance
|
||||
* To reduce code footprint, the examples folder is no longer included in composer deployments or github zip files
|
||||
* Trap low-level errors in SMTP, reports via debug output
|
||||
|
||||
## Version 5.2.23 (March 15th 2017)
|
||||
* Improve trapping of TLS errors during connection so that they don't cause warnings, and are reported better in debug output
|
||||
|
@ -959,7 +959,10 @@ class SMTP
|
||||
public function client_send($data)
|
||||
{
|
||||
$this->edebug("CLIENT -> SERVER: $data", self::DEBUG_CLIENT);
|
||||
return fwrite($this->smtp_conn, $data);
|
||||
set_error_handler(array($this, 'errorHandler'));
|
||||
$result = fwrite($this->smtp_conn, $data);
|
||||
restore_error_handler();
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user