# HG changeset patch # User cmlenz # Date 1200314865 0 # Node ID 43dca73da5b5140f86b31bff438f3342f6340ac5 # Parent 4e59524b0824d12df424eef37953bcbdaf17bb9c Fix for unicode problem when the previous message id is included as a comment in PO serialization. Closes #78. diff --git a/babel/messages/pofile.py b/babel/messages/pofile.py --- a/babel/messages/pofile.py +++ b/babel/messages/pofile.py @@ -422,10 +422,10 @@ _write('#%s\n' % ', '.join([''] + list(message.flags))) if message.previous_id and include_previous: - _write_comment(u'msgid %s' % _normalize(message.previous_id[0]), + _write_comment('msgid %s' % _normalize(message.previous_id[0]), prefix='|') if len(message.previous_id) > 1: - _write_comment(u'msgid_plural %s' % _normalize( + _write_comment('msgid_plural %s' % _normalize( message.previous_id[1] ), prefix='|')