Skip to content

Commit

Permalink
Fix incorrect sprintf
Browse files Browse the repository at this point in the history
  • Loading branch information
Uglymotha committed Dec 6, 2024
1 parent c8bc020 commit aceadc3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/igmpv3proxy.c
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ int main(int ArgCn, char *ArgVc[]) {
if (strlen(optarg) > 0) {
if (c == 'r' && !parseSubnetAddress(optarg, &addr, &mask)) {
i = optind, j = optind = 1;
if (! (opts[1] = malloc(strlen(optarg) + 1))) { // Freed by Self
if (! (opts[1] = malloc(strlen(optarg) + 2))) { // Freed by Self
fprintf(stderr, "Out of Memory!");
exit(-1);
}
Expand Down

0 comments on commit aceadc3

Please sign in to comment.