Skip to content

Commit

Permalink
libevent: fix leak
Browse files Browse the repository at this point in the history
Signed-off-by: David Korczynski <[email protected]>
  • Loading branch information
DavidKorczynski committed Sep 24, 2023
1 parent 5b4074a commit 4b67dac
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions projects/libevent/utils_fuzzer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
struct evutil_addrinfo *addr_info = NULL;
std::string s1 = data_provider.ConsumeRandomLengthString();
evutil_getaddrinfo(s1.c_str(), NULL, NULL, &addr_info);
if (addr_info != NULL) {
evutil_freeaddrinfo(addr_info);
}

return 0;
}

0 comments on commit 4b67dac

Please sign in to comment.