git: af907bb62414 - main - nfs server: only cn_pnbuf is initialized in nfsrvd_lookup()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 15 May 2025 09:12:19 UTC
The branch main has been updated by kib:
URL: https://cgit.FreeBSD.org/src/commit/?id=af907bb624141bd1aa1bd4586ea5b72d80780197
commit af907bb624141bd1aa1bd4586ea5b72d80780197
Author: Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2025-05-14 23:07:47 +0000
Commit: Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2025-05-15 01:07:52 +0000
nfs server: only cn_pnbuf is initialized in nfsrvd_lookup()
PR: 286796
Reviewed by: rmacklem
Sponsored by: The FreeBSD Foundation
---
sys/fs/nfsserver/nfs_nfsdserv.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sys/fs/nfsserver/nfs_nfsdserv.c b/sys/fs/nfsserver/nfs_nfsdserv.c
index a855d6548265..b26fc59bcd6d 100644
--- a/sys/fs/nfsserver/nfs_nfsdserv.c
+++ b/sys/fs/nfsserver/nfs_nfsdserv.c
@@ -628,8 +628,8 @@ nfsrvd_lookup(struct nfsrv_descript *nd, __unused int isdgram,
}
if (!nd->nd_repstat) {
/* Don't set OPENNAMED for Lookupp (".."). */
- if (cnp->cn_namelen == 2 && *cnp->cn_nameptr == '.' &&
- *(cnp->cn_nameptr + 1) == '.')
+ if (cnp->cn_namelen == 2 && *cnp->cn_pnbuf == '.' &&
+ *(cnp->cn_pnbuf + 1) == '.')
cnp->cn_flags &= ~OPENNAMED;
nd->nd_repstat = nfsvno_namei(nd, &named, dp, 0, exp, &dirp);
} else {