From: Eric W. Biederman Date: Thu, 20 Jul 2017 02:23:15 +0000 (-0500) Subject: signal: Ensure no siginfo union member increases the size of struct siginfo X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=aba1be2f8c26ea322dd9c43047c1aff90528f032;p=linux.git signal: Ensure no siginfo union member increases the size of struct siginfo Signed-off-by: "Eric W. Biederman" --- diff --git a/kernel/signal.c b/kernel/signal.c index 241d54958bbbc..b9e5d825ee462 100644 --- a/kernel/signal.c +++ b/kernel/signal.c @@ -3688,6 +3688,7 @@ void __init signals_init(void) /* If this check fails, the __ARCH_SI_PREAMBLE_SIZE value is wrong! */ BUILD_BUG_ON(__ARCH_SI_PREAMBLE_SIZE != offsetof(struct siginfo, _sifields._pad)); + BUILD_BUG_ON(sizeof(struct siginfo) != SI_MAX_SIZE); sigqueue_cachep = KMEM_CACHE(sigqueue, SLAB_PANIC); }