From 4d36b97543482652a6d7043f773e65a8e6508d37 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Fri, 5 Apr 2013 11:46:15 +0200 Subject: [PATCH] Check for $bounceAddress before using (fixes #3359) --- email/Mailer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/email/Mailer.php b/email/Mailer.php index 6d66112f6..ba5dda1d4 100644 --- a/email/Mailer.php +++ b/email/Mailer.php @@ -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); }