diff options
author | Kees Cook <keescook@chromium.org> | 2021-07-23 15:19:33 -0700 |
---|---|---|
committer | Kees Cook <keescook@chromium.org> | 2021-08-22 00:21:36 -0700 |
commit | a8fc576d4af2f23a87a586424252df97f0ad0b06 (patch) | |
tree | c45776a6dadc7d4ac3ad12683a12c89ef3eb0d5a /Makefile | |
parent | 1e2cd3084fff19e12bdf3c83ac1a8d64ef11aa63 (diff) |
lib/test_stackinit: Add assigned initializers
Add whole-variable assignments of cast static initializers. These appear
to currently behave like the direct initializers, but best to check them
too. For example:
struct test_big_hole var;
var = (struct test_big_hole){
.one = arg->one,
.two= arg->two,
.three = arg->three,
.four = arg->four };
Additionally adds a test for whole-object assignment, which is expected
to fail since it usually falls back to a memcpy():
var = *arg;
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/lkml/CAK8P3a20SEoYCrp3jOK32oZc9OkiPv+1KTjNZ2GxLbHpY4WexQ@mail.gmail.com
Cc: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20210723221933.3431999-4-keescook@chromium.org
Diffstat (limited to 'Makefile')
0 files changed, 0 insertions, 0 deletions