[Sound-open-firmware] [PATCH] klockwork: fix one uninitialized issue
From: Zhang Keqiao keqiao.zhang@intel.com
Signed-off-by: Zhang Keqiao keqiao.zhang@intel.com --- rimage/file_simple.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/rimage/file_simple.c b/rimage/file_simple.c index a9f22d0..6402b2e 100644 --- a/rimage/file_simple.c +++ b/rimage/file_simple.c @@ -259,7 +259,7 @@ static int simple_write_module_reloc(struct image *image, struct module *module) { struct snd_sof_mod_hdr hdr; size_t count; - int i, err; + int err;
hdr.num_blocks = 1; hdr.size = module->text_size + module->data_size; @@ -288,7 +288,7 @@ static int simple_write_module_reloc(struct image *image, struct module *module)
err = write_block_reloc(image, module); if (err < 0) { - fprintf(stderr, "error: failed to write section #%d\n", i); + fprintf(stderr, "error: failed to write section\n"); return err; }
I had sent it for this previously. Thanks.
Yan Wang
On Fri, 2018-04-20 at 19:09 +0800, Zhang Keqiao wrote:
From: Zhang Keqiao keqiao.zhang@intel.com
Signed-off-by: Zhang Keqiao keqiao.zhang@intel.com
rimage/file_simple.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/rimage/file_simple.c b/rimage/file_simple.c index a9f22d0..6402b2e 100644 --- a/rimage/file_simple.c +++ b/rimage/file_simple.c @@ -259,7 +259,7 @@ static int simple_write_module_reloc(struct image *image, struct module *module) { struct snd_sof_mod_hdr hdr; size_t count;
- int i, err;
- int err;
hdr.num_blocks = 1; hdr.size = module->text_size + module->data_size; @@ -288,7 +288,7 @@ static int simple_write_module_reloc(struct image *image, struct module *module) err = write_block_reloc(image, module); if (err < 0) {
fprintf(stderr, "error: failed to write section
#%d\n", i);
fprintf(stderr, "error: failed to write section\n");
return err; }
participants (2)
-
yanwang
-
Zhang Keqiao