binfmt: Use struct_size()
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 28 May 2023 16:20:24 +0000 (18:20 +0200)
committerKees Cook <keescook@chromium.org>
Tue, 30 May 2023 22:49:46 +0000 (15:49 -0700)
commite6302d5a285b41209ada308ced6f9562cf1c616f
tree91a7773c80fe52634754ed986eec1e5d4c828359
parent60592fb6b67c653beaa2e7acad9a9d7aa0b71dff
binfmt: Use struct_size()

Use struct_size() instead of hand-writing it. It is less verbose, more
robust and more informative.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Acked-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/53150beae5dc04dac513dba391a2e4ae8696a7f3.1685290790.git.christophe.jaillet@wanadoo.fr
fs/binfmt_elf_fdpic.c