summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Mailman/OutgoingQueue.py21
1 files changed, 13 insertions, 8 deletions
diff --git a/Mailman/OutgoingQueue.py b/Mailman/OutgoingQueue.py
index 6435cfa56..776deffcf 100644
--- a/Mailman/OutgoingQueue.py
+++ b/Mailman/OutgoingQueue.py
@@ -36,9 +36,21 @@
# only one such process to happen at a time.
#
-import os, stat, tempfile, marshal, errno, mm_cfg
+import os
+import stat
+import marshal
+import errno
+import mm_cfg
import Utils
+# We need the version of tempfile.py from Python 1.5.2 because it has
+# provisions for uniquifying filenames in concurrent children after a fork.
+# If not using Python 1.5.2's version, let's get our copy of the new file.
+import tempfile
+if not hasattr(tempfile, '_pid'):
+ from Mailman.pythonlib import tempfile
+assert hasattr(tempfile, '_pid')
+
TEMPLATE = "mm_q."
#
# multiple prcesses with different uids can write and/or
@@ -170,10 +182,3 @@ def deferMessage(q_entry):
#
def dequeueMessage(q_entry):
os.unlink(q_entry)
-
-
-
-
-
-
-