summaryrefslogtreecommitdiffstats
path: root/Lib/gettext.py
diff options
context:
space:
mode:
authorAndrew Kuchling <amk@amk.ca>2015-04-14 14:35:43 (GMT)
committerAndrew Kuchling <amk@amk.ca>2015-04-14 14:35:43 (GMT)
commit19ddaf6d40efd69d7c5292a24a5bd78b5166465a (patch)
tree381cd81153944d30c59f8547b5e87b1b9356a655 /Lib/gettext.py
parent467a546b5ea4ca4112f3cc4ae1f7c0c39a8ad0cf (diff)
parentb3c30d91143be72a05a02b9eb5f7b2e670450288 (diff)
downloadcpython-19ddaf6d40efd69d7c5292a24a5bd78b5166465a.zip
cpython-19ddaf6d40efd69d7c5292a24a5bd78b5166465a.tar.gz
cpython-19ddaf6d40efd69d7c5292a24a5bd78b5166465a.tar.bz2
Merge from 3.4
Diffstat (limited to 'Lib/gettext.py')
-rw-r--r--Lib/gettext.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/gettext.py b/Lib/gettext.py
index 5292633..101378f 100644
--- a/Lib/gettext.py
+++ b/Lib/gettext.py
@@ -275,11 +275,12 @@ class GNUTranslations(NullTranslations):
# See if we're looking at GNU .mo conventions for metadata
if mlen == 0:
# Catalog description
- lastk = k = None
+ lastk = None
for b_item in tmsg.split('\n'.encode("ascii")):
item = b_item.decode().strip()
if not item:
continue
+ k = v = None
if ':' in item:
k, v = item.split(':', 1)
k = k.strip().lower()