af_unix: preserve const qualifier in unix_sk()
authorEric Dumazet <edumazet@google.com>
Fri, 17 Mar 2023 15:55:35 +0000 (15:55 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sat, 18 Mar 2023 12:23:33 +0000 (12:23 +0000)
commitb064ba9c3cfaf3d22d6153ec3c245eaa4d913674
tree3f76755a82c18f25a1ad11a16f4baeb63c4a3053
parentae6084b739925d84ef4a481d8eaa2187455f2e2f
af_unix: preserve const qualifier in unix_sk()

We can change unix_sk() to propagate its argument const qualifier,
thanks to container_of_const().

We need to change dump_common_audit_data() 'struct unix_sock *u'
local var to get a const attribute.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/af_unix.h
security/lsm_audit.c