mirror of
https://github.com/opnsense/src.git
synced 2026-06-14 19:20:18 -04:00
nfscl: Check for an error return from nfsrv_getattrbits()
There were two places where the client code did not check for a parse error return from nfsrv_getattrbits(). This patch fixes both of these cases. Reported by: rtm@lcs.mit.edu Tested by: rtm@lcs.mit.edu PR: 260272 MFC after: 2 weeks
This commit is contained in:
parent
d9931c2561
commit
ab639f2398
1 changed files with 6 additions and 2 deletions
|
|
@ -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 ||
|
||||
|
|
|
|||
Loading…
Reference in a new issue