Commit ff42357e authored by Koosha KM's avatar Koosha KM Committed by David Lawrence

Bug 1095758: Fix use of uninitialized value $hostname in Mailer.pm

r=dkl,a=glob
parent 0b19b103
......@@ -116,7 +116,7 @@ sub MessageToMTA {
# address, but other mailers won't.
my $urlbase = Bugzilla->params->{'urlbase'};
$urlbase =~ m|//([^:/]+)[:/]?|;
$hostname = $1;
$hostname = $1 || 'localhost';
$from .= "\@$hostname" if $from !~ /@/;
$email->header_set('From', $from);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment