Mercurial > public > mercurial-scm > hg-stable
diff tests/test-clone.t @ 20825:dda11e799529 stable
hg: use "os.path.join()" to join path components which may be empty (issue4203)
Changset 2d0ab571b822 rewriting "hg.copystore()" with vfs uses
'dstbase + "/lock"' instead of "os.path.join()", because target files
given from "store.copyfiles()" already uses "/" as path separator
But in the repository using revlog format 0, "dstbase" becomes empty
("data" directory is located under ".hg" directly), and 'dstbase +
"/lock"' is treated as "/lock": in almost all cases, write access to
"/lock" causes "permission denied".
This patch uses "os.path.join()" to join path components which may be
empty in "hg.copystore()".
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Tue, 25 Mar 2014 19:34:17 +0900 |
parents | e54a078153f7 |
children | 4bc1fd86e915 |
line wrap: on
line diff
--- a/tests/test-clone.t Mon Mar 24 21:27:40 2014 -0400 +++ b/tests/test-clone.t Tue Mar 25 19:34:17 2014 +0900 @@ -621,3 +621,17 @@ #endif $ cd .. + +Test clone from the repository in (emulated) revlog format 0 (issue4203): + + $ mkdir issue4203 + $ mkdir -p src/.hg + $ echo foo > src/foo + $ hg -R src add src/foo + $ hg -R src commit -m '#0' + $ hg -R src log -q + 0:e1bab28bca43 + $ hg clone -U -q src dst + $ hg -R dst log -q + 0:e1bab28bca43 + $ cd ..