bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] symlink lookups in ext2fs


From: Moritz Schulte
Subject: Re: [PATCH] symlink lookups in ext2fs
Date: Mon, 03 Dec 2001 21:41:01 +0100
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.1

Roland McGrath <address@hidden> writes:

> A patch without a bug report is almost always ignored.

Sorry, I thought it was obvious, since it's a little change.

Here the bug, now in verbose mode:

address@hidden:~$ touch foo
address@hidden:~$ ln -s foo foo2
address@hidden:~$ ln -s $PWD/foo foo3
address@hidden:~$ ls -l foo*
-rw-r--r--    1 moritz   moritz          0 Dec  3 23:56 foo
lrwxr-xr-x    1 moritz   moritz          3 Dec  3 23:56 foo2 -> foo
lrwxr-xr-x    1 moritz   moritz         16 Dec  3 23:56 foo3 -> /home/moritz/foo
address@hidden:~$ ls foo2/
ls: foo2/: Not a directory
address@hidden:~$ ls foo3/
foo3/
address@hidden:~$ 

The point is that the lookup on 'foo3/' succeeds, which is wrong,
IMHO.  ENOTDIR should be returned, just like on the lookup of 'foo2/'.

The reason is that diskfs_S_dir_lookup() didn't append a trailing
slash to the retryname, if the lookup had a trailing slash appended.

                moritz
-- 
address@hidden - http://duesseldorf.ccc.de/~moritz/
GPG fingerprint = 3A14 3923 15BE FD57 FC06  B501 0841 2D7B 6F98 4199



reply via email to

[Prev in Thread] Current Thread [Next in Thread]