From: Yaakov Selkowitz <[email protected]> POSIX.1-2008 Base Definitions 4.12 ("Pathname Resolution") states:
"A pathname that begins with two successive <slash> characters may be interpreted in an implementation-defined manner, although more than two leading <slash> characters shall be treated as a single <slash> character." On Cygwin, paths with exactly two leading slashes are mapped to their backslash-subsituted Windows UNC equivalents. Therefore "/usr" and "//usr" are explicitely not the same path, while "/usr/foo" and "/usr//foo" are, as on other platforms. We must therefore ignore the empty '' component created from the leading slash. While it is not strictly necessary later on, it does not hurt to ignore extra slashes either. Signed-off-by: Yaakov Selkowitz <[email protected]> --- mkdirhier | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/mkdirhier b/mkdirhier index 09b89ee..c33c389 100644 --- a/mkdirhier +++ b/mkdirhier @@ -43,6 +43,10 @@ do for filename do + if [ "$filename" = '' ]; then + continue + fi + path=$prefix$filename prefix=$path/ shift -- 1.7.0.4 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
