Re: tilde-bug in vfs.c
- From: Oskar Liljeblad <oskar osk mine nu>
- To: Pavel Roskin <proski gnu org>
- Cc: mc-devel gnome org
- Subject: Re: tilde-bug in vfs.c
- Date: Thu, 5 Sep 2002 22:52:19 +0200
On Thursday, September 05, 2002 at 16:16, Pavel Roskin wrote:
> What does your patch implement? How does it work? Please always comment
> non-obvious patches. In this case we really should make a decision before
> we go ahead and patch the code.
Oh, I thought it was so simple. :) Anyway, vfs_canon is modified to
first canonicalize without tilde expansion. If this expanded file
exists (according to the vfs's stat function), this name is returned.
Otherwise, vfs_canon will simply canonicalize *with* tilde expansion
and return the result.
To accomplish this it was necessary to create a new function
vfs_canon_internal that can canonicalize either with tilde expansion
The drawback is that vfs_canon in worst case takes twice as long,
plus the time for the vfs stat call.
Oskar Liljeblad (oskar osk mine nu)
] [Thread Prev