relpath: Properly handle a "." directory name.

oldstable
Alexandre Julliard 2006-08-15 17:32:41 +02:00
parent dd8f067fb0
commit 65c9113e8f
1 changed files with 3 additions and 0 deletions

View File

@ -30,6 +30,9 @@ static const char *get_relative_path( const char *from, const char *dest, unsign
#define DIR_END(p) (*(p) == 0 || *(p) == '/')
const char *start;
/* a path of "." is equivalent to an empty path */
if (!strcmp( from, "." )) from = "";
*dotdots = 0;
for (;;)
{