# HG changeset patch # User Matt Mackall # Date 2006-12-03 22:16:33 # Node ID 29d91e57d055f27725cf77b4e395c2bb1d4cf422 # Parent f96c158ea3a3920b3b45cfd7da8b80b6efe757a1 Handle transcoding of username and description in changelog diff --git a/mercurial/changelog.py b/mercurial/changelog.py --- a/mercurial/changelog.py +++ b/mercurial/changelog.py @@ -61,10 +61,10 @@ class changelog(revlog): if not text: return (nullid, "", (0, 0), [], "", {}) last = text.index("\n\n") - desc = text[last + 2:] + desc = util.tolocal(text[last + 2:]) l = text[:last].split('\n') manifest = bin(l[0]) - user = l[1] + user = util.tolocal(l[1]) extra_data = l[2].split(' ', 2) if len(extra_data) != 3: @@ -88,6 +88,8 @@ class changelog(revlog): def add(self, manifest, list, desc, transaction, p1=None, p2=None, user=None, date=None, extra={}): + user, desc = util.fromlocal(user), util.fromlocal(desc) + if date: parseddate = "%d %d" % util.parsedate(date) else: