wireproto: use pushkey.decodekey
authorPierre-Yves David <pierre-yves.david@fb.com>
Tue, 27 May 2014 15:02:51 -0700
changeset 21653 4188cae727ce
parent 21652 ed6e61eaebc0
child 21654 ddf9a00c1239
wireproto: use pushkey.decodekey
mercurial/wireproto.py
--- a/mercurial/wireproto.py	Tue May 27 15:00:20 2014 -0700
+++ b/mercurial/wireproto.py	Tue May 27 15:02:51 2014 -0700
@@ -317,11 +317,7 @@
         self.ui.debug('preparing listkeys for "%s"\n' % namespace)
         yield {'namespace': encoding.fromlocal(namespace)}, f
         d = f.value
-        r = {}
-        for l in d.splitlines():
-            k, v = l.split('\t')
-            r[encoding.tolocal(k)] = encoding.tolocal(v)
-        yield r
+        yield pushkeymod.decodekeys(d)
 
     def stream_out(self):
         return self._callstream('stream_out')