summaryrefslogtreecommitdiff
path: root/Mailman/Utils.py
diff options
context:
space:
mode:
authorbwarsaw2003-05-12 05:44:12 +0000
committerbwarsaw2003-05-12 05:44:12 +0000
commitce253d3bd08a367e0adddbc5bb023c028e17d804 (patch)
tree57d362375aedfbb746520e725a5ca3ab4ccabcfd /Mailman/Utils.py
parent50d323824b0dfc9e60c425e374e5e6be33fcfb3d (diff)
downloadmailman-ce253d3bd08a367e0adddbc5bb023c028e17d804.tar.gz
mailman-ce253d3bd08a367e0adddbc5bb023c028e17d804.tar.zst
mailman-ce253d3bd08a367e0adddbc5bb023c028e17d804.zip
Diffstat (limited to 'Mailman/Utils.py')
-rw-r--r--Mailman/Utils.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/Mailman/Utils.py b/Mailman/Utils.py
index ceb63f66b..4a644342c 100644
--- a/Mailman/Utils.py
+++ b/Mailman/Utils.py
@@ -360,6 +360,17 @@ def websafe(s):
return cgi.escape(s, quote=1)
+def nntpsplit(s):
+ parts = s.split(':', 1)
+ if len(parts) == 2:
+ try:
+ return parts[0], int(parts[1])
+ except ValueError:
+ pass
+ # Use the defaults
+ return s, 119
+
+
# Just changing these two functions should be enough to control the way
# that email address obscuring is handled.