GNU bug report logs -
#8035
Processing of .. in a file path after going thru symlink
Previous Next
Reported by: spucci <slpnabble <at> blackberry-hill.com>
Date: Mon, 14 Feb 2011 05:50:03 UTC
Severity: normal
Tags: moreinfo
Fixed in version 28.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
Message #34 received at 8035 <at> debbugs.gnu.org (full text, mbox):
> From: Lars Ingebrigtsen <larsi <at> gnus.org>
> Cc: slpnabble <at> blackberry-hill.com, 8035 <at> debbugs.gnu.org
> Date: Thu, 26 Aug 2021 19:03:24 +0200
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> >> I'm guessing it's calling expand-file-name here to resolve "~"?
> >
> > No, because we always must call expand-file-name before invoking a
> > libc function that accesses files -- to support file names relative to
> > their buffer's default-directory.
>
> These are absolute file names, though. I can understand expanding if
> they're not.
You asked why expand-file-name is there in general, so I gave a
general explanation.
expand-file-name also normalizes file names, though. Which is also
needed in some use cases, e.g. when the /foo/bar/ isn't accessible,
but /foo/ is, in which case failing to normalize /foo/bar/../quux
could fail some file I/O function.
This bug report was last modified 3 years and 270 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.