Explorar o código

nfsd4: fix alloc_init_session BUILD_BUG_ON()

Note we're allocating an array of nfsd4_slot *'s, not nfsd4_slot's.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
J. Bruce Fields %!s(int64=14) %!d(string=hai) anos
pai
achega
c23753dac1
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      fs/nfsd/nfs4state.c

+ 1 - 1
fs/nfsd/nfs4state.c

@@ -657,7 +657,7 @@ alloc_init_session(struct svc_rqst *rqstp, struct nfs4_client *clp,
 	if (status)
 		goto out;
 
-	BUILD_BUG_ON(NFSD_MAX_SLOTS_PER_SESSION * sizeof(struct nfsd4_slot)
+	BUILD_BUG_ON(NFSD_MAX_SLOTS_PER_SESSION * sizeof(struct nfsd4_slot *)
 		     + sizeof(struct nfsd4_session) > PAGE_SIZE);
 
 	status = nfserr_jukebox;