From: Simon Glass Date: Sun, 1 May 2016 23:12:24 +0000 (-0600) Subject: fit_image: Fix a double close() on the error path X-Git-Tag: v2016.05~34 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=4c1dc1a90fb60c2e5f28351b6ff2ae187dc587ef;p=u-boot fit_image: Fix a double close() on the error path There is an extra close() call which is not needed. Reported-by: Coverity (CID: 143065) Signed-off-by: Simon Glass --- diff --git a/tools/fit_image.c b/tools/fit_image.c index ddefa72f34..0551572b04 100644 --- a/tools/fit_image.c +++ b/tools/fit_image.c @@ -343,7 +343,6 @@ static int fit_build(struct image_tool_params *params, const char *fname) if (ret != size) { fprintf(stderr, "%s: Can't write %s: %s\n", params->cmdname, fname, strerror(errno)); - close(fd); goto err; } close(fd);