summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2007-06-18 01:57:09 +0200
committermkanat%bugzilla.org <>2007-06-18 01:57:09 +0200
commitd13c46a25138d15b29293855a336f4e90645e694 (patch)
treee2beb254b4afa84a2f112be4ce1b9312ff0c0b24
parentcc9913464d0ae6ea5df6d0debcd2d622c001457e (diff)
downloadbugzilla-d13c46a25138d15b29293855a336f4e90645e694.tar.gz
bugzilla-d13c46a25138d15b29293855a336f4e90645e694.tar.xz
Bug 384497: Add a parameter that enables debug mode for SMTP
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=mkanat
-rw-r--r--Bugzilla/Config/MTA.pm6
-rw-r--r--Bugzilla/Mailer.pm3
-rw-r--r--template/en/default/admin/params/mta.html.tmpl5
3 files changed, 12 insertions, 2 deletions
diff --git a/Bugzilla/Config/MTA.pm b/Bugzilla/Config/MTA.pm
index 3415677f3..686d5b3e4 100644
--- a/Bugzilla/Config/MTA.pm
+++ b/Bugzilla/Config/MTA.pm
@@ -68,7 +68,11 @@ sub get_param_list {
type => 't',
default => 'localhost'
},
-
+ {
+ name => 'smtp_debug',
+ type => 'b',
+ default => 0
+ },
{
name => 'whinedays',
type => 't',
diff --git a/Bugzilla/Mailer.pm b/Bugzilla/Mailer.pm
index 1d4a90a4f..ab54ecfea 100644
--- a/Bugzilla/Mailer.pm
+++ b/Bugzilla/Mailer.pm
@@ -100,7 +100,8 @@ sub MessageToMTA {
if ($method eq "SMTP") {
push @args, Host => Bugzilla->params->{"smtpserver"},
- Hello => $hostname;
+ Hello => $hostname,
+ Debug => Bugzilla->params->{'smtp_debug'};
}
if ($method eq "Test") {
diff --git a/template/en/default/admin/params/mta.html.tmpl b/template/en/default/admin/params/mta.html.tmpl
index 778f81d0a..7af38ed6d 100644
--- a/template/en/default/admin/params/mta.html.tmpl
+++ b/template/en/default/admin/params/mta.html.tmpl
@@ -56,6 +56,11 @@
smtpserver => "The SMTP server address (if using SMTP for mail delivery).",
+ smtp_debug => "If enabled, this will print detailed information to your" _
+ " web server's error log about the communication between" _
+ " $terms.Bugzilla and your SMTP server. You can use this to" _
+ " troubleshoot email problems.",
+
whinedays => "The number of days that we'll let a $terms.bug sit untouched in a NEW " _
"state before our cronjob will whine at the owner.<br> " _
"Set to 0 to disable whining.",