Skip to content

Commit

Permalink
attempt to avoid codeQL false positive free-after-use exception (#225)
Browse files Browse the repository at this point in the history
  • Loading branch information
liquidaty authored Oct 13, 2024
1 parent eb3a20c commit 2ef8148
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/zsv.c
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ ZSV_EXPORT enum zsv_status zsv_set_fixed_offsets(zsv_parser parser, size_t count

free(parser->fixed.offsets);
parser->fixed.offsets = calloc(count, sizeof(*parser->fixed.offsets));
if (!parser->fixed.offsets) {
if (parser->fixed.offsets == NULL) {
fprintf(stderr, "Out of memory!\n");
return zsv_status_memory;
}
Expand Down

0 comments on commit 2ef8148

Please sign in to comment.