git: 61152df00aee - main - nfs_nfsdport.c: Do unnecessary initializations to quiet gcc
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 21 Jun 2026 00:09:19 UTC
The branch main has been updated by rmacklem:
URL: https://cgit.FreeBSD.org/src/commit/?id=61152df00aee248bec2ef267c092b6004e25f6d6
commit 61152df00aee248bec2ef267c092b6004e25f6d6
Author: Rick Macklem <rmacklem@FreeBSD.org>
AuthorDate: 2026-06-21 00:06:45 +0000
Commit: Rick Macklem <rmacklem@FreeBSD.org>
CommitDate: 2026-06-21 00:06:45 +0000
nfs_nfsdport.c: Do unnecessary initializations to quiet gcc
Fixes: d8e8f9251975 ("pNFSd: Add a directory of newly created files for the pNFSd")
---
sys/fs/nfsserver/nfs_nfsdport.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/sys/fs/nfsserver/nfs_nfsdport.c b/sys/fs/nfsserver/nfs_nfsdport.c
index ca8c9575bf59..16b74f0cded8 100644
--- a/sys/fs/nfsserver/nfs_nfsdport.c
+++ b/sys/fs/nfsserver/nfs_nfsdport.c
@@ -3137,6 +3137,7 @@ nfsrvd_readdirplus(struct nfsrv_descript *nd, int isdgram,
long pathval;
bool has_caseinsensitive, has_hiddensystem, has_namedattr, xattrsupp;
+ NFSZERO_ATTRBIT(&savbits); /* Shut up gcc. */
if (nd->nd_repstat) {
nfsrv_postopattr(nd, getret, &at);
goto out;
@@ -5303,7 +5304,7 @@ static void
nfsrv_pnfscreate(struct vnode *vp, struct vattr *vap, struct ucred *cred,
NFSPROC_T *p)
{
- struct nfsrvdscreate *dsc, *tdsc;
+ struct nfsrvdscreate *dsc, *tdsc = NULL; /* Shut up gcc. */
struct nfsdevice *ds, *tds, *fds;
struct mount *mp;
struct pnfsdsfile *pf, *tpf;
@@ -5677,7 +5678,7 @@ nfsrv_pnfsremove(struct vnode **dvpp, int dsfilecnt, char *fname,
fhandle_t *fhp, NFSPROC_T *p)
{
struct ucred *tcred;
- struct nfsrvdsremove *dsrm, *tdsrm;
+ struct nfsrvdsremove *dsrm, *tdsrm = NULL; /* Shut up gcc. */
struct nfsdevice *ds;
struct nfsmount *nmp;
struct vnode **tdvpp;
@@ -6057,10 +6058,10 @@ nfsrv_dsgetsockmnt(struct vnode *vp, int lktype, char *buf, int *buflenp,
char **devid, char *fnamep, struct vnode **nvpp, struct nfsmount **newnmpp,
struct nfsmount *curnmp, int *ippos, int *dsdirp)
{
- struct vnode *dvp, *nvp = NULL, **tdvpp;
+ struct vnode *dvp, *nvp = NULL, **tdvpp = NULL; /* Shut up gcc. */
struct mount *mp;
struct nfsmount *nmp, *newnmp;
- fhandle_t *tfhp;
+ fhandle_t *tfhp = NULL; /* Shut up gcc. */
struct sockaddr *sad;
struct sockaddr_in *sin;
struct nfsdevice *ds, *tds, *fndds;
@@ -7375,7 +7376,7 @@ nfsrv_setattrdsrpc(fhandle_t *fhp, struct vnode *vp, struct ucred *cred,
NFSPROC_T *p, struct nfsmount **nmp, int mirrorcnt, int stripecnt,
struct nfsvattr *nap, int *failposp)
{
- struct nfsrvsetattrdsdorpc *drpc, *tdrpc;
+ struct nfsrvsetattrdsdorpc *drpc, *tdrpc = NULL; /* Shut up gcc. */
fhandle_t *tfhp;
struct nfsmount **tnmp;
struct nfsvattr na;
@@ -7642,7 +7643,7 @@ nfsrv_getattrdsrpc(fhandle_t *fhp, struct vnode *vp, struct ucred *cred,
NFSPROC_T *p, struct nfsmount **nmp, int stripecnt, struct nfsvattr *nap,
int *failposp)
{
- struct nfsrvgetattrdsdorpc *drpc, *tdrpc;
+ struct nfsrvgetattrdsdorpc *drpc, *tdrpc = NULL; /* Shut up gcc. */
fhandle_t *tfhp;
struct nfsmount **tnmp;
int error, i, ret, timo;