Bug 217240 - namei ignores non-directory components instead of saying "Not a directory"
Summary: namei ignores non-directory components instead of saying "Not a directory"
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: util-linux
Version: 6
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Karel Zak
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-11-25 16:02 UTC by Matt McCutchen
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-12-15 15:08:34 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Matt McCutchen 2006-11-25 16:02:50 UTC
Description of problem:
If I pass namei a path "a/b", where "a" exists but is not a directory, namei
ignores the "a" component and tries to access "b" in the current directory.  It
should complain that "a" is "Not a directory".

Version-Release number of selected component (if applicable):
util-linux-2.13-0.44

How reproducible:
Always

Steps to Reproduce:
$ mkdir foo
$ cd foo
$ touch a b
$ namei a/b
  
Actual output:
f: a/b
 - a
 - b

Expected output:
f: a/b
 ? a - Not a directory (20)

Comment 1 Matt McCutchen 2006-12-17 15:14:13 UTC
Perhaps it would be more correct to say ENOTDIR instead of ENOENT?


Note You need to log in before you can comment on or make changes to this bug.