diff roundup/mailgw.py @ 1665:dc543c28a7d0

handle missing Subject: line [SF#755331]
author Richard Jones <richard@users.sourceforge.net>
date Wed, 18 Jun 2003 23:34:52 +0000
parents 2ff95415ffb2
children d4e615fcbe04
line wrap: on
line diff
--- a/roundup/mailgw.py	Wed Jun 18 23:31:52 2003 +0000
+++ b/roundup/mailgw.py	Wed Jun 18 23:34:52 2003 +0000
@@ -73,7 +73,7 @@
 an exception, the original message is bounced back to the sender with the
 explanatory message given in the exception. 
 
-$Id: mailgw.py,v 1.122 2003-06-18 23:31:52 richard Exp $
+$Id: mailgw.py,v 1.123 2003-06-18 23:34:52 richard Exp $
 '''
 
 import string, re, os, mimetools, cStringIO, smtplib, socket, binascii, quopri
@@ -487,6 +487,11 @@
         # handle the subject line
         subject = message.getheader('subject', '')
 
+        if not subject:
+            raise MailUsageError, '''
+Emails to Roundup trackers must include a Subject: line!
+'''
+
         if subject.strip().lower() == 'help':
             raise MailUsageHelp
 

Roundup Issue Tracker: http://roundup-tracker.org/