From eea6df8255bdf7d64124140bd1f138af3c9ed2ee Mon Sep 17 00:00:00 2001 From: Furong Xu Date: Tue, 14 Feb 2017 21:25:01 +0800 Subject: [PATCH] tools: patch-image: fix file descriptor leak. Maybe this is committed by mistake, fix it. Signed-off-by: Furong Xu --- tools/patch-image/src/patch-dtb.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/tools/patch-image/src/patch-dtb.c b/tools/patch-image/src/patch-dtb.c index 8d186236c1..a94da3fa41 100644 --- a/tools/patch-image/src/patch-dtb.c +++ b/tools/patch-image/src/patch-dtb.c @@ -49,10 +49,6 @@ int main(int argc, char **argv) search_space = dtb_max_size = atoi(argv[3]); } - fddtb = open(argv[1], O_RDONLY); - if (!fddtb) - goto err1; - if (stat(argv[2], &s)) { fprintf(stderr, "DTB not found\n"); goto err1; -- 2.25.1