diff mercurial/streamclone.py @ 8531:810387f59696

filelog encoding: move the encoding/decoding into store the escaping of directories ending with .i or .d doesn't really belong to filelog. we put the encoding/decoding in store instead, for backwards compat, streamclone and the fncache file format still uses the partially encoded filenames.
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Wed, 20 May 2009 18:35:47 +0200
parents 46293a0c7e9f
children 0289f384e1e5
line wrap: on
line diff
--- a/mercurial/streamclone.py	Wed May 20 18:35:41 2009 +0200
+++ b/mercurial/streamclone.py	Wed May 20 18:35:47 2009 +0200
@@ -8,6 +8,8 @@
 import util, error
 from i18n import _
 
+from mercurial import store
+
 class StreamException(Exception):
     def __init__(self, code):
         Exception.__init__(self)
@@ -46,7 +48,8 @@
         try:
             repo.ui.debug(_('scanning\n'))
             for name, ename, size in repo.store.walk():
-                entries.append((name, size))
+                # for backwards compat, name was partially encoded
+                entries.append((store.encodedir(name), size))
                 total_bytes += size
         finally:
             lock.release()