From: Al Viro Date: Wed, 10 Sep 2025 22:41:52 +0000 (-0400) Subject: nfsctl: symlink has no business bumping link count of parent directory X-Git-Tag: v6.18-rc1~126^2~4 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7e6135fe7b483cd85e28789d70e09cc91064be95;p=thirdparty%2Fkernel%2Fstable.git nfsctl: symlink has no business bumping link count of parent directory mkdir should incrment the parent's refcount; symlink should not. Reviewed-by: NeilBrown Reviewed-by: Jeff Layton Signed-off-by: Al Viro --- diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index bc6b776fc6575..282b961d87883 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -1181,7 +1181,6 @@ static int __nfsd_symlink(struct inode *dir, struct dentry *dentry, inode->i_size = strlen(content); d_add(dentry, inode); - inc_nlink(dir); fsnotify_create(dir, dentry); return 0; }