summaryrefslogtreecommitdiffstats
path: root/tools/mkzenboot.c
diff options
context:
space:
mode:
authorThomas Jarosch <tomj@simonv.com>2014-12-20 15:18:46 +0100
committerThomas Jarosch <tomj@simonv.com>2014-12-20 15:18:46 +0100
commit61e322c840e9ca434b24dcd27b5d576a4bf03a40 (patch)
tree3eee4e70999a83f6ef9382dcb2bd3a93aec91685 /tools/mkzenboot.c
parent1eb1bc24f2debaaaef31db2872c800bd4d98fcf4 (diff)
downloadrockbox-61e322c840e9ca434b24dcd27b5d576a4bf03a40.tar.gz
rockbox-61e322c840e9ca434b24dcd27b5d576a4bf03a40.tar.bz2
rockbox-61e322c840e9ca434b24dcd27b5d576a4bf03a40.zip
mkzenboot: Fix double close of bootfd on error
cppcheck reported: [rockbox/tools/mkzenboot.c:1176]: (error) Used file that is not opened. Change-Id: Ibbf7ab2910c7f43b547fef25c62e0b4d19ff9551
Diffstat (limited to 'tools/mkzenboot.c')
-rw-r--r--tools/mkzenboot.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/tools/mkzenboot.c b/tools/mkzenboot.c
index 1ee9952bf0..b345c0f5ac 100644
--- a/tools/mkzenboot.c
+++ b/tools/mkzenboot.c
@@ -1173,7 +1173,6 @@ int mkboot(const char* infile, const char* bootfile, const char* outfile, struct
if(fwrite(&out_buffer[i+8+le2int(&out_buffer[i+4])], ciff_size-i-8-le2int(&out_buffer[i+4]), 1, outfd) != 1)
{
log_message("[ERR] Short write\n");
- fclose(bootfd);
fclose(outfd);
free(out_buffer);
return -28;