netlink_smc_diag: fix off-by-one error in xlat lookup
* netlink_smc_diag.c (decode_smc_diag_shutdown): Decrement xlat size by one to account for XLAT_END as other users of xlats do. Fixes: v4.25~54 "netlink_smc_diag: decode SMC_DIAG_SHUTDOWN attribute value"
This commit is contained in:
parent
986a55423e
commit
73f565d1b8
@ -136,7 +136,7 @@ decode_smc_diag_shutdown(struct tcb *const tcp,
|
||||
const void *const opaque_data)
|
||||
{
|
||||
const struct decode_nla_xlat_opts opts = {
|
||||
ARRSZ_PAIR(sock_shutdown_flags), "???_SHUTDOWN",
|
||||
ARRSZ_PAIR(sock_shutdown_flags) - 1, "???_SHUTDOWN",
|
||||
.size = 1,
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user