Check for $bounceAddress before using (fixes #3359)

This commit is contained in:
Ingo Schommer 2013-04-05 11:46:15 +02:00
parent 97819b3f21
commit 4d36b97543

View File

@ -224,7 +224,7 @@ class Mailer extends Object {
$to = $this->validEmailAddr($to);
// Try it without the -f option if it fails
if(!($result = @mail($to, $subject, $fullBody, $headers, escapeshellarg("-f$bounceAddress")))) {
if(!$bounceAddress || !($result = @mail($to, $subject, $fullBody, $headers, escapeshellarg("-f$bounceAddress")))) {
$result = mail($to, $subject, $fullBody, $headers);
}