Email for std.path submissions

bobef bobef at lessequal.com
Fri Feb 24 06:32:23 PST 2006


Miles wrote:
> bobef wrote:
>> 	version(t_Linux)
>> 	{
>> 		(...)
>> 		writefln("\ngetFullPath tests\n");
>>
>> 		writefln(getFullPath("\\rabbit/..\\bird"));
>> 		writefln(getFullPath("\\rabbit\\cat\\..\\bird"));
>> 		writefln(getFullPath("\\rabbit\\..\\bird"));
>> 		writefln(getFullPath("rabbit.d"));
>> 		writefln(getFullPath("rabbit\\..\\.\\bird"));
>> 		writefln(getFullPath(".\\rabbit\\..\\.\\bird\\..\\"));
> 
> It is not correct to remove '..' on Linux. '/a/../b' is not garanteed to
> be '/b', since '/a' could be a symbolic link to somewhere else on the
> filesystem.
> 

Never thought of that.
And I think it is also not correct to replace \ with / in the Linux 
paths... I don't have enough Linux knowledge to solve these yet.



More information about the Digitalmars-d mailing list