selinux: fix typo in selinux_netlbl_sctp_sk_clone declaration
authorArnd Bergmann <arnd@arndb.de>
Fri, 23 Feb 2018 21:12:09 +0000 (22:12 +0100)
committerPaul Moore <paul@paul-moore.com>
Mon, 26 Feb 2018 22:45:32 +0000 (17:45 -0500)
A missing 'struct' keyword caused a build error when CONFIG_NETLABEL
is disabled:

In file included from security/selinux/hooks.c:99:
security/selinux/include/netlabel.h:135:66: error: unknown type name 'sock'
 static inline void selinux_netlbl_sctp_sk_clone(struct sock *sk, sock *newsk)
                                                                  ^~~~
security/selinux/hooks.c: In function 'selinux_sctp_sk_clone':
security/selinux/hooks.c:5188:2: error: implicit declaration of function 'selinux_netlbl_sctp_sk_clone'; did you mean 'selinux_netlbl_inet_csk_clone'? [-Werror=implicit-function-declaration]

Fixes: db97c9f9d312 ("selinux: Add SCTP support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Paul Moore <paul@paul-moore.com>
security/selinux/include/netlabel.h

index 6ef4953431dc3e109dedb1cebfe37b03322f01c9..8671de09c36379081fecc42f307aca29e37893aa 100644 (file)
@@ -132,7 +132,8 @@ static inline void selinux_netlbl_inet_csk_clone(struct sock *sk, u16 family)
 {
        return;
 }
-static inline void selinux_netlbl_sctp_sk_clone(struct sock *sk, sock *newsk)
+static inline void selinux_netlbl_sctp_sk_clone(struct sock *sk,
+                                               struct sock *newsk)
 {
        return;
 }