~ubuntu-branches/ubuntu/hardy/mailman/hardy-updates

« back to all changes in this revision

Viewing changes to debian/patches/74_admin_non-ascii_emails.dpatch

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2006-10-30 13:00:30 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20061030130030-hvz4ipqc82e3wbi6
Tags: 1:2.1.9-2ubuntu1
* Synchronize to Debian; remaining Ubuntu change:
  - debian/control: exim4 -> postfix.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#! /bin/sh /usr/share/dpatch/dpatch-run
2
 
## 74_admin_non-ascii_emails.dpatch by  <lionel@mamane.lu>
3
 
##
4
 
## All lines beginning with `## DP:' are a description of the patch.
5
 
## DP: Don't assume emails are ASCII
6
 
 
7
 
@DPATCH@
8
 
diff -urNad mailman-2.1.5~/Mailman/Cgi/admin.py mailman-2.1.5/Mailman/Cgi/admin.py
9
 
--- mailman-2.1.5~/Mailman/Cgi/admin.py 2003-12-24 18:27:45.000000000 +0100
10
 
+++ mailman-2.1.5/Mailman/Cgi/admin.py  2005-11-15 00:55:12.881669479 +0100
11
 
@@ -867,7 +867,12 @@
12
 
     chunksz = mlist.admin_member_chunksize
13
 
     # The email addresses had /better/ be ASCII, but might be encoded in the
14
 
     # database as Unicodes.
15
 
-    all = [_m.encode() for _m in mlist.getMembers()]
16
 
+    all = []
17
 
+    for _m in mlist.getMembers():
18
 
+        try:
19
 
+            all.append( _m.encode() )
20
 
+        except:
21
 
+            all.append( _m )
22
 
     all.sort(lambda x, y: cmp(x.lower(), y.lower()))
23
 
     # See if the query has a regular expression
24
 
     regexp = cgidata.getvalue('findmember', '').strip()