commit | acea4f59d947f08d4eb7b0ed0cf04b3d88d4484c | [log] [tgz] |
---|---|---|
author | Mikhail Ilin <ilin.mikhail.ol@gmail.com> | Wed Nov 23 14:31:03 2022 +0300 |
committer | Tom Rini <trini@konsulko.com> | Thu Dec 08 09:29:02 2022 -0500 |
tree | af689d28aa1eacaa60ac8d0d9748a2f37f7dd981 | |
parent | fc0453dee40a09fe2c1ffa1ce88ca252edfec7ed [diff] |
tools: fdtgrep: Fix handle leak The handle "fd" was created in fdtgrep.c:708 by calling the "open" function and is lost in fdtgrep.c:716 and fdtgrep.c:723. Close file descriptor 'fd' before exiting with an error from function utilfdt_read_err_len(const char *filename, char **buffp, off_t *len). Fixes: 1043d0a0296a ("fdt: Add fdtgrep tool") Signed-off-by: Mikhail Ilin <ilin.mikhail.ol@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>