remote-hg: always normalize paths

Apparently Mercurial can have paths such as 'foo//bar', so normalize all
paths.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Felipe Contreras 2014-04-09 13:50:01 -05:00 committed by Junio C Hamano
parent fe45cfb518
commit 867bf7b490

View File

@ -260,6 +260,7 @@ class Parser:
return (user, int(date), -tz)
def fix_file_path(path):
path = os.path.normpath(path)
if not os.path.isabs(path):
return path
return os.path.relpath(path, '/')