[wp-trac] [WordPress Trac] #28909: Update PHPMailer to 5.2.10

WordPress Trac noreply at wordpress.org
Tue Jul 7 22:18:20 UTC 2015


#28909: Update PHPMailer to 5.2.10
------------------------------------+-----------------------
 Reporter:  MattyRob                |       Owner:  ocean90
     Type:  task (blessed)          |      Status:  assigned
 Priority:  normal                  |   Milestone:  4.3
Component:  External Libraries      |     Version:  4.0
 Severity:  normal                  |  Resolution:
 Keywords:  has-patch dev-feedback  |     Focuses:
------------------------------------+-----------------------

Comment (by ocean90):

 @dd32 Thanks for your investigations. I want to add that this happens
 because `wp_new_comment()` triggers `wp_mail()` which contains a single
 line of 65535 characters long.

 I did a look at [attachment:28909.unit-test-vars.diff] and it does fix the
 unit tests for me. It has one bug in `MockPHPMailer::preSend()`:
 `parent:preSend()` needs to be returned.
 I'll vote for the change to MockPHPMailer instead of re-creating the
 `$phpmailer` global but I'm not quite sure why we need to reset
 `$this->encoding`.
 I hadn't the time to test what happens when we send two mails via
 wp_mail() with `PHPMailer::postSend()` since core creates only one
 instance of  `$phpmailer` too, so we wouldn't reset `$this->encoding` in
 this case.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/28909#comment:48>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list