diff options
| author | Barry Warsaw | 2011-06-10 20:03:16 -0400 |
|---|---|---|
| committer | Barry Warsaw | 2011-06-10 20:03:16 -0400 |
| commit | 56e3d0431002758bf8fa395ae607674a50024157 (patch) | |
| tree | ad8f2826b6e7d8b74ee83ff0fb55230f511a4f6e /src | |
| parent | f8596ce463863dc6defb5dac84f5b226c45cb419 (diff) | |
| download | mailman-56e3d0431002758bf8fa395ae607674a50024157.tar.gz mailman-56e3d0431002758bf8fa395ae607674a50024157.tar.zst mailman-56e3d0431002758bf8fa395ae607674a50024157.zip | |
Diffstat (limited to 'src')
| -rw-r--r-- | src/mailman/bin/master.py | 4 | ||||
| -rw-r--r-- | src/mailman/mta/base.py | 8 | ||||
| -rw-r--r-- | src/mailman/mta/postfix.py | 10 |
3 files changed, 5 insertions, 17 deletions
diff --git a/src/mailman/bin/master.py b/src/mailman/bin/master.py index ee15adbaa..d982b385f 100644 --- a/src/mailman/bin/master.py +++ b/src/mailman/bin/master.py @@ -463,9 +463,9 @@ class Loop: # Are we permanently non-restartable? log.debug("""\ Master detected subprocess exit -(pid: {0:d}, why: {1}, class: {2}, slice: {3:d}/{4:d}) {5}""", +(pid: {0:d}, why: {1}, class: {2}, slice: {3:d}/{4:d}) {5}""".format( pid, why, rname, slice_number + 1, count, - ('[restarting]' if restart else '')) + ('[restarting]' if restart else ''))) # See if we've reached the maximum number of allowable restarts. if restarts > max_restarts: log.info("""\ diff --git a/src/mailman/mta/base.py b/src/mailman/mta/base.py index 69b1d9c5c..e90fbcf8f 100644 --- a/src/mailman/mta/base.py +++ b/src/mailman/mta/base.py @@ -21,7 +21,6 @@ from __future__ import absolute_import, unicode_literals __metaclass__ = type __all__ = [ - 'BaseAliases', 'BaseDelivery', 'IndividualDelivery', ] @@ -169,10 +168,3 @@ class IndividualDelivery(BaseDelivery): mlist, message_copy, msgdata_copy, [recipient]) refused.update(status) return refused - - - -class BaseAliases: - """Common alias generation; use as a mixin.""" - - diff --git a/src/mailman/mta/postfix.py b/src/mailman/mta/postfix.py index a4fe0f331..b52ce20a6 100644 --- a/src/mailman/mta/postfix.py +++ b/src/mailman/mta/postfix.py @@ -120,12 +120,8 @@ class LMTP: for mlist in sorted(by_domain[domain], key=sort_key): utility = getUtility(IMailTransportAgentAliases) aliases = list(utility.aliases(mlist)) - longest = max(len(alias) for alias in aliases) - print >> fp, ALIASTMPL.format( - aliases.pop(0), config, - # Add 1 because the bare list name has no dash. - longest + 3) + width = max(len(alias) for alias in aliases) + 3 + print >> fp, ALIASTMPL.format(aliases.pop(0), config, width) for alias in aliases: - print >> fp, ALIASTMPL.format( - alias, config, longest + 3) + print >> fp, ALIASTMPL.format(alias, config, width) print >> fp |
