Apply 59_fix_missing_language_crash.patch
authorMichael Spang <mspang@uwaterloo.ca>
Thu, 13 Sep 2007 00:32:56 +0000 (20:32 -0400)
committerMichael Spang <mspang@uwaterloo.ca>
Thu, 13 Sep 2007 00:32:56 +0000 (20:32 -0400)
Mailman/htmlformat.py

index 1a0bd22..00625ea 100644 (file)
@@ -298,7 +298,7 @@ class Document(Container):
 
     def Format(self, indent=0, **kws):
         charset = 'us-ascii'
-        if self.language:
+        if self.language and Utils.IsLanguage(self.language):
             charset = Utils.GetCharSet(self.language)
         output = ['Content-Type: text/html; charset=%s\n' % charset]
         if not self.suppress_head: