aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorRick Macklem <rmacklem@FreeBSD.org>2021-12-09 22:32:22 +0000
committerRick Macklem <rmacklem@FreeBSD.org>2021-12-09 22:32:22 +0000
commitab639f2398bf7efd4dfd38cd6527e22f6e781ae9 (patch)
tree466d60912ec1e87739b6af5188a437a59185386f /sys
parentd9931c25617d6625e280fda19bd9c2878e49c091 (diff)
Diffstat (limited to 'sys')
-rw-r--r--sys/fs/nfsclient/nfs_clrpcops.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/fs/nfsclient/nfs_clrpcops.c b/sys/fs/nfsclient/nfs_clrpcops.c
index 7646c1b404da..08bfac3575f7 100644
--- a/sys/fs/nfsclient/nfs_clrpcops.c
+++ b/sys/fs/nfsclient/nfs_clrpcops.c
@@ -2513,7 +2513,9 @@ nfsrpc_createv4(vnode_t dvp, char *name, int namelen, struct vattr *vap,
stateid.other[1] = *tl++;
stateid.other[2] = *tl;
rflags = fxdr_unsigned(u_int32_t, *(tl + 6));
- (void) nfsrv_getattrbits(nd, &attrbits, NULL, NULL);
+ error = nfsrv_getattrbits(nd, &attrbits, NULL, NULL);
+ if (error)
+ goto nfsmout;
NFSM_DISSECT(tl, u_int32_t *, NFSX_UNSIGNED);
deleg = fxdr_unsigned(int, *tl);
if (deleg == NFSV4OPEN_DELEGATEREAD ||
@@ -8154,7 +8156,9 @@ nfsrpc_createlayout(vnode_t dvp, char *name, int namelen, struct vattr *vap,
stateid.other[0] = *tl++;
stateid.other[1] = *tl++;
stateid.other[2] = *tl;
- nfsrv_getattrbits(nd, &attrbits, NULL, NULL);
+ error = nfsrv_getattrbits(nd, &attrbits, NULL, NULL);
+ if (error != 0)
+ goto nfsmout;
NFSM_DISSECT(tl, u_int32_t *, NFSX_UNSIGNED);
deleg = fxdr_unsigned(int, *tl);
if (deleg == NFSV4OPEN_DELEGATEREAD ||