fix: Correct sendmail_path validation to ensure proper formatting for sender address
This commit is contained in:
parent
14e1efe293
commit
0d4c5ee8da
|
|
@ -2111,7 +2111,7 @@ class PHPMailer
|
|||
}
|
||||
if (!empty($this->Sender) && static::validateAddress($this->Sender)) {
|
||||
$phpmailer_path = ini_get('sendmail_path');
|
||||
if (self::isShellSafe($this->Sender) && strpos($phpmailer_path, '-f') === false) {
|
||||
if (self::isShellSafe($this->Sender) && strpos($phpmailer_path, ' -f') === false) {
|
||||
$params = sprintf('-f%s', $this->Sender);
|
||||
}
|
||||
$old_from = ini_get('sendmail_from');
|
||||
|
|
|
|||
Loading…
Reference in New Issue