diff options
author | Andy Lutomirski <luto@kernel.org> | 2016-03-22 17:25:10 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-03-22 18:36:02 -0400 |
commit | 2bf8c47626599c54ab072a29ef1c294d3cce6b0a (patch) | |
tree | 9595247538725427399c56fdd050e366d7c3b4cc /net/xfrm | |
parent | 96c0e0a908ecfa61118d49db85c03e162b7f6e20 (diff) |
net/xfrm_user: use in_compat_syscall to deny compat syscalls
The code wants to prevent compat code from receiving messages. Use
in_compat_syscall for this.
Signed-off-by: Andy Lutomirski <luto@kernel.org>
Cc: Steffen Klassert <steffen.klassert@secunet.com>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'net/xfrm')
-rw-r--r-- | net/xfrm/xfrm_user.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c index 805681a7d356..2cc7af858c6f 100644 --- a/net/xfrm/xfrm_user.c +++ b/net/xfrm/xfrm_user.c | |||
@@ -2449,7 +2449,7 @@ static int xfrm_user_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
2449 | int type, err; | 2449 | int type, err; |
2450 | 2450 | ||
2451 | #ifdef CONFIG_COMPAT | 2451 | #ifdef CONFIG_COMPAT |
2452 | if (is_compat_task()) | 2452 | if (in_compat_syscall()) |
2453 | return -ENOTSUPP; | 2453 | return -ENOTSUPP; |
2454 | #endif | 2454 | #endif |
2455 | 2455 | ||