Re: file command bug on windows
- From: Óscar Fuentes <ofv@xxxxxxxxxx>
- Date: Mon, 06 Apr 2009 02:21:09 +0200
Mark Janssen <mpc.janssen@xxxxxxxxx> writes:
The fact that ~something is interpreted as a home directory is working
as documented and is useful in windows as well as in Unix.
The manual page for `filename` on Tcl 8.4.13 says this:
<- begin quote ->
The Macintosh and Windows platforms do not support tilde substitution
when a user name follows the tilde. On these platforms, attempts to use
a tilde followed by a user name will generate an error that the user
does not exist when Tcl attempts to interpret that part of the path or
otherwise access the file. The behaviour of these paths when not trying
to interpret them is the same as on Unix. File names that have a tilde
without a user name will be correctly substituted using the $HOME
environment variable, just like for Unix.
<- end quote ->
However, on Windows 2000:
(bin) 12 % file normalize ~hello
user "hello" doesn't exist
(bin) 13 % file normalize ~Administrator
D:/
So the documentation seems wrong for this specific part of tilde
expansion.
(and it is a real pleasure to discover that an user can make your app to
err just choosing a filename that is perfectly okay on his platform) :-/
--
Oscar
.
- References:
- Re: file command bug on windows
- From: solar
- Re: file command bug on windows
- From: Gerald W. Lester
- Re: file command bug on windows
- From: solar
- Re: file command bug on windows
- From: Mark Janssen
- Re: file command bug on windows
- Prev by Date: Re: file command bug on windows
- Next by Date: Re: file command bug on windows
- Previous by thread: Re: file command bug on windows
- Next by thread: Problem sourcing files in child interpreters in Starkit
- Index(es):
Relevant Pages
|