diff options
| author | Mikhail Ilin <[email protected]> | 2022-11-23 13:48:44 +0300 |
|---|---|---|
| committer | Stefano Babic <[email protected]> | 2023-01-30 23:23:01 +0100 |
| commit | 9017785acd247c6ba60d0f0c0e9722201f0b184c (patch) | |
| tree | 3ea005fdf76b0043ab6eb4a6f5d72158b0228ca8 /tools/imx8mimage.c | |
| parent | 507a70b1447ae389c614ac3d04ae853922935898 (diff) | |
tools: imx8mimage: Fix handle leak
The handle "fd" was created in imx8mimage.c:178 by calling
the "fopen" function and is lost in imx8mimage.c:210.
Should close the 'fd' file descriptor before exiting
the parse_cfg_file(char *name) function.
Fixes: 6609c2663c9c ("tools: add i.MX8M image support")
Signed-off-by: Mikhail Ilin <[email protected]>
Diffstat (limited to 'tools/imx8mimage.c')
| -rw-r--r-- | tools/imx8mimage.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/imx8mimage.c b/tools/imx8mimage.c index 35d0a92bfdf..3ca79d865aa 100644 --- a/tools/imx8mimage.c +++ b/tools/imx8mimage.c @@ -207,6 +207,7 @@ static uint32_t parse_cfg_file(char *name) } } + fclose(fd); return 0; } |
