src/bin/jpwl/convert.c pgxtoimage(): add missing fclose() (#977)

This commit is contained in:
Even Rouault 2017-08-09 09:50:39 +02:00
parent 5a560ebf51
commit 0eceb4494c
1 changed files with 2 additions and 0 deletions

View File

@ -1352,6 +1352,7 @@ opj_image_t* pgxtoimage(const char *filename, opj_cparameters_t *parameters)
&endian2, signtmp, &prec, temp, &w, temp, &h) != 9) {
fprintf(stderr,
"ERROR: Failed to read the right number of element from the fscanf() function!\n");
fclose(f);
return NULL;
}
@ -1371,6 +1372,7 @@ opj_image_t* pgxtoimage(const char *filename, opj_cparameters_t *parameters)
bigendian = 0;
} else {
fprintf(stderr, "Bad pgx header, please check input file\n");
fclose(f);
return NULL;
}