]> git.itanic.dy.fi Git - linux-stable/commit
modpost: refactor check_sec_ref()
authorMasahiro Yamada <masahiroy@kernel.org>
Sat, 7 Oct 2023 17:04:47 +0000 (02:04 +0900)
committerMasahiro Yamada <masahiroy@kernel.org>
Wed, 18 Oct 2023 08:16:09 +0000 (17:16 +0900)
commit29ae5c02ed743c62e3c0619013b2bcd280bc562d
tree0c1b797e78582d7d6c4d1b36326e966df71af756
parentbd78c9d714208fb5d989bd8ad007ff0e2bcfb2a9
modpost: refactor check_sec_ref()

We can replace &elf->sechdrs[i] with &sechdrs[i] to slightly shorten
the code because we already have the local variable 'sechdrs'.

However, defining 'sechdr' instead shortens the code further.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
scripts/mod/modpost.c