Overrides the PHPMailer::isSendmail() method to remove the restriction on the name of the sendmail binary's name and to read the sendmail path configured in the global configuration (defaulting to PHP's sendmail_path if something isn't set in the global config and ultimately defaulting to /usr/sbin/sendmail if neither of those give a path).
Testing Instructions
Set a custom sendmail path in the global config, send a message using it, and ensure PHPMailer uses the correct binary path.
tested with sucess!
Used
/sbin/sendmail
as sendmail binary path.And used "Send Test mail" button with the Mailer set to "Sendmail"
Before patch
After patch
The "error" is because the usage of
escapeshellarg
is not allowed on the server.But for this test is enough.