Merge remote-tracking branch 'remotes/origin/master' into 6.0
# Conflicts: # examples/gmail_xoauth.phps # src/PHPMailer.php
This commit is contained in:
commit
c33a3a7824
|
|
@ -47,9 +47,12 @@ This is a major update that breaks backwards compatibility.
|
|||
* 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
|
||||
|
||||
* Handle bare codes (an RFC contravention) in SMTP server responses
|
||||
* Make message timestamps more dynamic - calculate the date separately for each message
|
||||
|
||||
## 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
|
||||
* Amend test suite so it uses PHPUnit version 4.8, compatible with older versions of PHP, instead of teh version supplied by Travis-CI
|
||||
* Amend test suite so it uses PHPUnit version 4.8, compatible with older versions of PHP, instead of the version supplied by Travis-CI
|
||||
* This forces pinning of some dev packages to older releases, but should make travis builds more reliable
|
||||
* Test suite now runs on HHVM, and thus so should PHPMailer in general
|
||||
* Improve Czech translations
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@ $mail->SMTPAuth = true;
|
|||
$mail->AuthType = 'XOAUTH2';
|
||||
|
||||
//Fill in authentication details here
|
||||
//Either the gmail account owner, or the user that gave consent
|
||||
$email = 'someone@gmail.com';
|
||||
$clientId = 'RANDOMCHARS-----duv1n2.apps.googleusercontent.com';
|
||||
$clientSecret = 'RANDOMCHARS-----lGyjPcRtvP';
|
||||
|
|
|
|||
|
|
@ -2096,10 +2096,7 @@ class PHPMailer
|
|||
{
|
||||
$result = '';
|
||||
|
||||
if ('' == $this->MessageDate) {
|
||||
$this->MessageDate = static::rfcDate();
|
||||
}
|
||||
$result .= $this->headerLine('Date', $this->MessageDate);
|
||||
$result .= $this->headerLine('Date', $this->MessageDate == '' ? self::rfcDate() : $this->MessageDate);
|
||||
|
||||
// To be created automatically by mail()
|
||||
if ($this->SingleTo) {
|
||||
|
|
|
|||
|
|
@ -1064,8 +1064,10 @@ class SMTP
|
|||
$this->edebug("SMTP -> get_lines(): \$data is \"$data\"", self::DEBUG_LOWLEVEL);
|
||||
$this->edebug("SMTP -> get_lines(): \$str is \"$str\"", self::DEBUG_LOWLEVEL);
|
||||
$data .= $str;
|
||||
// If 4th character is a space, we are done reading, break the loop, micro-optimisation over strlen
|
||||
if ((isset($str[3]) and $str[3] == ' ')) {
|
||||
// If response is only 3 chars (not valid, but RFC5321 S4.2 says it must be handled),
|
||||
// or 4th character is a space, we are done reading, break the loop,
|
||||
// string array access is a micro-optimisation over strlen
|
||||
if (!isset($str[3]) or (isset($str[3]) and $str[3] == ' ')) {
|
||||
break;
|
||||
}
|
||||
// Timed-out? Log and break
|
||||
|
|
|
|||
Loading…
Reference in New Issue