##// END OF EJS Templates
subrepo: make "_sanitize()" take absolute path to the root of subrepo...
subrepo: make "_sanitize()" take absolute path to the root of subrepo Before this patch, "hg update" doesn't sanitize ".hg/hgrc" in non-hg subrepos correctly, if "hg update" is executed not at the root of the parent repository. "_sanitize()" takes relative path to subrepo from the root of the parent repository, and passes it to "os.walk()". In this case, "os.walk()" expects CWD to be equal to the root of the parent repository. So, "os.walk()" can't find specified path (or may scan unexpected path), if CWD isn't equal to the root of the parent repository. Non-hg subrepo under nested hg-subrepos may cause same problem, too: CWD may be equal to the root of the outer most repository, or so. This patch makes "_sanitize()" take absolute path to the root of subrepo to sanitize correctly in such cases. This patch doesn't normalize the path to hostile files as the one relative to CWD (or the root of the outer most repository), to fix the problem in the simple way suitable for "stable". Normalizing should be done in the future: maybe as a part of the migration to vfs.
FUJIWARA Katsunori -
r21566:a01988cd stable
Show More
Name Size Modified Last Commit Author
/ mercurial / help
common.txt Loading ...
config.txt Loading ...
dates.txt Loading ...
diffs.txt Loading ...
environment.txt Loading ...
extensions.txt Loading ...
filesets.txt Loading ...
glossary.txt Loading ...
hg.1.txt Loading ...
hgignore.5.txt Loading ...
hgignore.txt Loading ...
hgrc.5.txt Loading ...
hgweb.txt Loading ...
merge-tools.txt Loading ...
multirevs.txt Loading ...
patterns.txt Loading ...
phases.txt Loading ...
revisions.txt Loading ...
revsets.txt Loading ...
subrepos.txt Loading ...
templates.txt Loading ...
urls.txt Loading ...