summaryrefslogtreecommitdiffstats
path: root/sys/gnu/ext2fs
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>1999-03-02 05:31:47 +0000
committerimp <imp@FreeBSD.org>1999-03-02 05:31:47 +0000
commitf86ebee5a71b73933ccd7a7f52876d3e5b25278f (patch)
tree2f4306be0470a471af27074cb4ae23c5ecbaf9d2 /sys/gnu/ext2fs
parent0909dd46f23a09222d7e523f8c663f0f281339ad (diff)
downloadFreeBSD-src-f86ebee5a71b73933ccd7a7f52876d3e5b25278f.zip
FreeBSD-src-f86ebee5a71b73933ccd7a7f52876d3e5b25278f.tar.gz
Merge patch to ufs_vnops.c's ufs_rename to the copy of ufs_rename that
lives in ext2_vnops.c for ext2fs. Also remove cast from comparision. Bruce pointed out that it was bogus since we'd force a signed comparision when we really wanted an unsigned comparison.
Diffstat (limited to 'sys/gnu/ext2fs')
-rw-r--r--sys/gnu/ext2fs/ext2_vnops.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/gnu/ext2fs/ext2_vnops.c b/sys/gnu/ext2fs/ext2_vnops.c
index 8463a30..006687b 100644
--- a/sys/gnu/ext2fs/ext2_vnops.c
+++ b/sys/gnu/ext2fs/ext2_vnops.c
@@ -482,6 +482,11 @@ abortit:
goto abortit;
dp = VTOI(fdvp);
ip = VTOI(fvp);
+ if (ip->i_nlink >= LINK_MAX) {
+ VOP_UNLOCK(fvp, 0, p);
+ error = EMLINK;
+ goto abortit;
+ }
if ((ip->i_flags & (NOUNLINK | IMMUTABLE | APPEND))
|| (dp->i_flags & APPEND)) {
VOP_UNLOCK(fvp, 0, p);
OpenPOWER on IntegriCloud