fs/namei.c lookup_flags is misleading

Keith Owens (kaos@ocs.com.au)
Wed, 20 Jun 2001 16:37:54 +1000


2.4.6-pre3 and earlier. fs/namei.c:lookup_flags() checks for O_CREATE,
it even has a comment saying that O_CREATE|O_EXCL is a special case.
But the only place lookup_flags() is called has

if (!(flag & O_CREAT)) {
if (path_init(pathname, lookup_flags(flag), nd))

so O_CREATE can never be set. Not a bug, just misleading. It does not
help that path_walk() has a variable called lookup_flags.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/