summaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
authorKoosha KM <koosha.khajeh@gmail.com>2014-11-12 21:13:11 +0100
committerDavid Lawrence <dkl@mozilla.com>2014-11-12 21:13:11 +0100
commite4da3e9bd67ce8c306157eb07ce5c36997af1696 (patch)
tree65c108a79c70b01160f3c80a5bcfbeb92ce52fc9 /Bugzilla
parentc0156f20dfd3f5bfa3a0e1c2b6ca0f2de34797a4 (diff)
downloadbugzilla-e4da3e9bd67ce8c306157eb07ce5c36997af1696.tar.gz
bugzilla-e4da3e9bd67ce8c306157eb07ce5c36997af1696.tar.xz
Bug 1095758: Fix use of uninitialized value $hostname in Mailer.pm
r=dkl,a=glob
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/Mailer.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/Bugzilla/Mailer.pm b/Bugzilla/Mailer.pm
index 389b6f69e..bcf17458f 100644
--- a/Bugzilla/Mailer.pm
+++ b/Bugzilla/Mailer.pm
@@ -154,7 +154,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);