]> Git Repo - linux.git/commit - net/sctp/diag.c
sctp: Fix a big endian bug in sctp_diag_dump()
authorDan Carpenter <[email protected]>
Mon, 25 Sep 2017 10:19:26 +0000 (13:19 +0300)
committerDavid S. Miller <[email protected]>
Wed, 27 Sep 2017 04:16:29 +0000 (21:16 -0700)
commitc2cc187e53011c1c4931055984657da9085c763b
tree45ccf097fc85211099c24611e05eee2eece6ee6f
parent20c62c797e85b589152970089eaf22a7d88d989a
sctp: Fix a big endian bug in sctp_diag_dump()

The sctp_for_each_transport() function takes an pointer to int.  The
cb->args[] array holds longs so it's only using the high 32 bits.  It
works on little endian system but will break on big endian 64 bit
machines.

Fixes: d25adbeb0cdb ("sctp: fix an use-after-free issue in sctp_sock_dump")
Signed-off-by: Dan Carpenter <[email protected]>
Acked-by: Neil Horman <[email protected]>
Reviewed-by: Xin Long <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
net/sctp/sctp_diag.c
This page took 0.056423 seconds and 4 git commands to generate.