Skip to contentSkip to conversation

af_unix: constify the sock parameter in unix_sk()

PATCH Applied Paul Moore 2 participants 2 messages Oct 6, 2015 – Oct 8, 2015

Subsystems (3)
lore
Share & tools
lore

Paul Moore

author
#0 lore raw

PATCH 1/1 af_unix: constify the sock parameter in unix_sk()

Make unix_sk() just like inet[6]_sk() by constify'ing the sock parameter.

---
 include/net/af_unix.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/net/af_unix.h +1 -1
index cb1b9bb..b36d837 100644
@@ -64,7 +64,7 @@ struct unix_sock {
 	struct socket_wq	peer_wq;
 };
 
-static inline struct unix_sock *unix_sk(struct sock *sk)
+static inline struct unix_sock *unix_sk(const struct sock *sk)
 {
 	return (struct unix_sock *)sk;
 }