]> granicus.if.org Git - openjpeg/commitdiff
Add missing fclose() statement in error condition.
authorGregory Fiumara <gregory.fiumara@nist.gov>
Fri, 20 Oct 2017 19:31:45 +0000 (15:31 -0400)
committerGregory Fiumara <gregory.fiumara@nist.gov>
Fri, 20 Oct 2017 19:31:45 +0000 (15:31 -0400)
src/bin/jpwl/convert.c

index d0ec4bd05bfedfbf432ac9b88c019d75979f583f..f3bb670b0a14c230d721862bc447dbf29179ac06 100644 (file)
@@ -737,6 +737,7 @@ opj_image_t* bmptoimage(const char *filename, opj_cparameters_t *parameters)
 
         if (fread(RGB, sizeof(unsigned char), (3 * W + PAD) * H,
                   IN) != (3 * W + PAD) * H) {
+            fclose(IN);
             free(RGB);
             opj_image_destroy(image);
             fprintf(stderr,