Commit 795de720 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(Fexpand_file_name): Fix expansion of "/foo/../".

parent 49fb5799
......@@ -1379,7 +1379,8 @@ See also the function `substitute-in-file-name'.")
{
while (o != target && (--o) && !IS_DIRECTORY_SEP (*o))
;
if (o == target && IS_ANY_SEP (*o))
/* Keep initial / only if this is the whole name. */
if (o == target && IS_ANY_SEP (*o) && p[3] == 0)
++o;
p += 3;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment