WSL2-Linux-Kernel/fs/nfs/filelayout
Dan Carpenter 769b01ea68 NFS: fix an incorrect limit in filelayout_decode_layout()
The "sizeof(struct nfs_fh)" is two bytes too large and could lead to
memory corruption.  It should be NFS_MAXFHSIZE because that's the size
of the ->data[] buffer.

I reversed the size of the arguments to put the variable on the left.

Fixes: 16b374ca43 ("NFSv4.1: pnfs: filelayout: add driver's LAYOUTGET and GETDEVICEINFO infrastructure")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
2021-05-20 12:17:08 -04:00
..
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
filelayout.c NFS: fix an incorrect limit in filelayout_decode_layout() 2021-05-20 12:17:08 -04:00
filelayout.h NFS store nfs4_deviceid in struct nfs4_filelayout_segment 2017-03-28 11:21:52 -04:00
filelayoutdev.c SUNRPC: Add xdr_set_scratch_page() and xdr_reset_scratch_buffer() 2020-11-30 14:46:35 -05:00