Skip to content

Commit

Permalink
wrong fcloses
Browse files Browse the repository at this point in the history
  • Loading branch information
iceman1001 committed Aug 3, 2023
1 parent 175e804 commit c6f2785
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tools/fpga_compress/fpga_compress.c
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ static int zlib_decompress(FILE *infile, FILE *outfiles[], uint8_t num_outfiles,
fseek(infile, 0L, SEEK_SET);
return EXIT_SUCCESS;
} else {
fclose(infile);

// seeking for trailing zeroes
long offset = 0;
long outfilesizes[10] = {0};
Expand Down Expand Up @@ -474,7 +474,6 @@ int main(int argc, char **argv) {
fprintf(stderr, "Error. Cannot open input file %s\n\n", argv[2]);

// close file handlers
fclose(infile);
for (uint16_t j = 0; j < num_output_files; j++) {
fclose(outfiles[j]);
}
Expand Down

0 comments on commit c6f2785

Please sign in to comment.