Skip to content

Commit

Permalink
Merge pull request #555 from ddiss/lkl_test_icmp_buf_overflow
Browse files Browse the repository at this point in the history
lkl tools: fix lkl_test_icmp malloc size
  • Loading branch information
tavip authored Jan 30, 2025
2 parents 74da3bd + b54c6b9 commit b357b84
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/lkl/tests/net-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ static int lkl_test_icmp(void)
}

for (i = 0; i < NUM_ICMP; i++) {
icmp = malloc(sizeof(struct lkl_icmphdr *));
icmp = malloc(sizeof(*icmp));
icmp->type = LKL_ICMP_ECHO;
icmp->code = 0;
icmp->checksum = 0;
Expand Down

0 comments on commit b357b84

Please sign in to comment.