manifest: fix buffer init in resign

Set buffer to NULL to prevent freeing bogus memory in error case.

Signed-off-by: Jaska Uimonen <jaska.uimonen@linux.intel.com>
This commit is contained in:
Jaska Uimonen 2021-12-01 21:48:48 +02:00 committed by Liam Girdwood
parent 3c232422a7
commit 0f64a20183
1 changed files with 1 additions and 1 deletions

View File

@ -1432,9 +1432,9 @@ out:
int resign_image(struct image *image) int resign_image(struct image *image)
{ {
int key_size, key_file_size; int key_size, key_file_size;
void *buffer = NULL;
size_t size, read; size_t size, read;
FILE *in_file; FILE *in_file;
void *buffer;
int ret, i; int ret, i;
/* open image for reading */ /* open image for reading */