summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authormux <mux@FreeBSD.org>2002-05-16 19:22:39 +0000
committermux <mux@FreeBSD.org>2002-05-16 19:22:39 +0000
commite621b864874c5a629be9b9be653ffe64e38dd6e6 (patch)
tree8336eb7217f3395a0bfeed8501156ae0ae38583d /sys
parent4009aa43de152606c655cf815548d7719f363b62 (diff)
downloadFreeBSD-src-e621b864874c5a629be9b9be653ffe64e38dd6e6.zip
FreeBSD-src-e621b864874c5a629be9b9be653ffe64e38dd6e6.tar.gz
In VOP_LOOKUP, don't assume that the final pathname component
will be in the same filesystem than the one where the current component is. Approved by: scottl
Diffstat (limited to 'sys')
-rw-r--r--sys/fs/udf/udf_vnops.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/fs/udf/udf_vnops.c b/sys/fs/udf/udf_vnops.c
index 3ae517c..0222a74 100644
--- a/sys/fs/udf/udf_vnops.c
+++ b/sys/fs/udf/udf_vnops.c
@@ -1035,8 +1035,7 @@ lookloop:
if (flags & MAKEENTRY)
cache_enter(dvp, *vpp, a->a_cnp);
- /* Why wait to the very end to decide that this is a read-only fs? */
- if (nameiop == CREATE || nameiop == RENAME)
+ if ((flags & ISLASTCN) && (nameiop == CREATE || nameiop == RENAME))
return (EROFS);
return (ENOENT);
OpenPOWER on IntegriCloud