mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
common: fit-sig: Fix error message in fit_config_verify_sig()
In fit_config_verify_sig(), when no 'signature*' subnode exists in the configuration node, the fdt_for_each_subnode() loop is a no-op. Therefore, no error flags are set, and 'err_,sg' is not populated with an error string. This is incorrect behavior. Populate err_msg to indicate that no 'signature' is found, before entering the loop. The first call to fit_image_verify_sig() will override clear err_msg, or set it to a more specific message. Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
b7cfe32e18
commit
76c78a5481
1 changed files with 1 additions and 1 deletions
|
@ -360,7 +360,7 @@ static int fit_config_verify_sig(const void *fit, int conf_noffset,
|
|||
const void *sig_blob, int sig_offset)
|
||||
{
|
||||
int noffset;
|
||||
char *err_msg = "";
|
||||
char *err_msg = "No 'signature' subnode found";
|
||||
int verified = 0;
|
||||
int ret;
|
||||
|
||||
|
|
Loading…
Reference in a new issue