[Mailman-checkins] [Branch ~mailman-coders/mailman/2.1] Rev 1813: Fixed missing <> in List-ID with invalid char in description.

2019-06-05 Thread noreply

revno: 1813
fixes bug: https://launchpad.net/bugs/1831321
committer: Mark Sapiro 
branch nick: 2.1
timestamp: Wed 2019-06-05 16:39:30 -0700
message:
  Fixed missing <> in List-ID with invalid char in description.
modified:
  Mailman/Handlers/CookHeaders.py
  NEWS


--
lp:mailman/2.1
https://code.launchpad.net/~mailman-coders/mailman/2.1

Your team Mailman Checkins is subscribed to branch lp:mailman/2.1.
To unsubscribe from this branch go to 
https://code.launchpad.net/~mailman-coders/mailman/2.1/+edit-subscription
=== modified file 'Mailman/Handlers/CookHeaders.py'
--- Mailman/Handlers/CookHeaders.py	2018-06-17 23:47:34 +
+++ Mailman/Handlers/CookHeaders.py	2019-06-05 23:39:30 +
@@ -328,6 +328,12 @@
 # 2047 encoded.
 i18ndesc = uheader(mlist, mlist.description, 'List-Id', maxlinelen=998)
 listid_h = formataddr((str(i18ndesc), listid))
+# With some charsets (utf-8?) and some invalid chars, str(18ndesc) can
+# be empty.
+if str(i18ndesc):
+listid_h = formataddr((str(i18ndesc), listid))
+else:
+listid_h = '<%s>' % listid
 else:
 # without desc we need to ensure the MUST brackets
 listid_h = '<%s>' % listid

=== modified file 'NEWS'
--- NEWS	2019-05-22 14:49:35 +
+++ NEWS	2019-06-05 23:39:30 +
@@ -43,6 +43,10 @@
 
 - Fixed the spelling of the --no-restart option for mailmanctl.
 
+- Fixed an issue where certain combinations of charset and invalid
+  characters in a list's description could produce a List-ID header
+  without angle brackets.  (LP: #1831321)
+
 2.1.29 (24-Jul-2018)
 
   Bug Fixes

___
Mailman-checkins mailing list
Mailman-checkins@python.org
Unsubscribe: 
https://mail.python.org/mailman/options/mailman-checkins/archive%40jab.org



[Mailman-checkins] [Branch ~mailman-coders/mailman/2.1] Rev 1813: Fixed missing <> in List-ID with invalid char in description.

2019-06-01 Thread noreply

revno: 1813
committer: Mark Sapiro 
branch nick: 2.1
timestamp: Sat 2019-06-01 15:24:38 -0700
message:
  Fixed missing <> in List-ID with invalid char in description.
modified:
  Mailman/Handlers/CookHeaders.py
  NEWS


--
lp:mailman/2.1
https://code.launchpad.net/~mailman-coders/mailman/2.1

Your team Mailman Checkins is subscribed to branch lp:mailman/2.1.
To unsubscribe from this branch go to 
https://code.launchpad.net/~mailman-coders/mailman/2.1/+edit-subscription
=== modified file 'Mailman/Handlers/CookHeaders.py'
--- Mailman/Handlers/CookHeaders.py	2018-06-17 23:47:34 +
+++ Mailman/Handlers/CookHeaders.py	2019-06-01 22:24:38 +
@@ -328,6 +328,12 @@
 # 2047 encoded.
 i18ndesc = uheader(mlist, mlist.description, 'List-Id', maxlinelen=998)
 listid_h = formataddr((str(i18ndesc), listid))
+# With some charsets (utf-8?) and some invalid chars, str(18ndesc) can
+# be empty.
+if str(i18ndesc):
+listid_h = formataddr((str(i18ndesc), listid))
+else:
+listid_h = '<%s>' % listid
 else:
 # without desc we need to ensure the MUST brackets
 listid_h = '<%s>' % listid

=== modified file 'NEWS'
--- NEWS	2019-05-22 14:49:35 +
+++ NEWS	2019-06-01 22:24:38 +
@@ -43,6 +43,10 @@
 
 - Fixed the spelling of the --no-restart option for mailmanctl.
 
+- Fixed an issue where certain combinations of charset and invalid
+  characters in a list's description could produce a List-ID header
+  without angle brackets.  (LP: #1831321)
+
 2.1.29 (24-Jul-2018)
 
   Bug Fixes

___
Mailman-checkins mailing list
Mailman-checkins@python.org
Unsubscribe: 
https://mail.python.org/mailman/options/mailman-checkins/archive%40jab.org