boot: android: Prevent use of unintialised variable
authorAndrew Goodbody <andrew.goodbody@linaro.org>
Thu, 26 Jun 2025 16:38:55 +0000 (17:38 +0100)
committerMattijs Korpershoek <mkorpershoek@kernel.org>
Wed, 2 Jul 2025 10:10:25 +0000 (12:10 +0200)
commit4b489f517366595cd3f003d4175e721bd927a18b
tree3769f1d87bbb490b17f2d1b7dbbf67ac2a64dabf
parent4b9717c6868f2f98b02fbe87a885cfa48a5b9946
boot: android: Prevent use of unintialised variable

Initialise vhdr to prevent its use when uninitialised.

This issue was found with Smatch.

Fixes: e058176be32b (android: boot: add vendor boot image to prepare for v3, v4 support)
Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Link: https://lore.kernel.org/r/20250625-abootimg_fix-v4-2-df7af00e87b0@linaro.org
Signed-off-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
boot/image-android.c