summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormailman1998-03-20 17:53:01 +0000
committermailman1998-03-20 17:53:01 +0000
commitbee5eb485b0584ea4dd9df29c767d4deeaa694e8 (patch)
treecf2f95398d9a211e7a8fed58df41c25fdb72db4a
parent93584779297c2db51351e77f3a37a97bb97345c1 (diff)
downloadmailman-bee5eb485b0584ea4dd9df29c767d4deeaa694e8.tar.gz
mailman-bee5eb485b0584ea4dd9df29c767d4deeaa694e8.tar.zst
mailman-bee5eb485b0584ea4dd9df29c767d4deeaa694e8.zip
We have been seeing problems when invoked in a tight loop from
senddigest with loss of the digest temp files. To aid debugging, we add an argument indicating the file when an ioerror is encountered in the process (but the IOError is still raised). See my next checkin, of mm_digest, for what seems to be the fix of the underlying problem.
-rwxr-xr-xmail/deliver8
1 files changed, 5 insertions, 3 deletions
diff --git a/mail/deliver b/mail/deliver
index 39f66f4a5..5aeeda2e4 100755
--- a/mail/deliver
+++ b/mail/deliver
@@ -1,6 +1,5 @@
#!/usr/local/bin/python
-#
-#
+
# Heh, heh, heh, this partition reminds me of the knapsack problem ;-)
# Ie, the optimal distribution here is NP Complete.
@@ -65,7 +64,10 @@ if not os.fork():
if spawns < 1:
spawns = 1
to_list = sys.argv[4:]
- file = open(sys.argv[1], 'r')
+ try:
+ file = open(sys.argv[1], 'r')
+ except IOError, msg:
+ raise IOError, (msg[0], msg[1], sys.argv[1])
text = file.read()
file.close()
os.unlink(sys.argv[1])