Skip to content

Commit

Permalink
low-level SMTP error handling from 6.0 branch (PHPMailer#1012) (PHPMa…
Browse files Browse the repository at this point in the history
  • Loading branch information
lewa authored and Synchro committed May 10, 2017
1 parent afb1302 commit 7280a55
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion class.smtp.php
Original file line number Diff line number Diff line change
Expand Up @@ -989,7 +989,10 @@ public function turn()
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;
}

/**
Expand Down

0 comments on commit 7280a55

Please sign in to comment.