Closed Payne-X6 closed 2 years ago
While testing our application running on libkqueue we have found memory leak using clang -fsanitize=address.
clang -fsanitize=address
We are using libkqueue-2.3.1 but it seems to be failing also on older versions.
libkqueue-2.3.1
For reproduce just init kqueue file descriptor. Code to reproduce:
main.c
// clang -g -O0 -Wall -fsanitize=address -fno-omit-frame-pointer -lkqueue main.c #include <stdio.h> #include <unistd.h> #include <errno.h> #include <sys/event.h> int main(void) { // Init kqueue int fd = kqueue(); if (fd < 0) { return errno; } // Close kqueue should deinit close(fd); // Should be clear return 0; }
I've pushed some changes recently that'll ensure any pending kqueue frees are processed before the process exits, this should now be fixed... at least on Linux.
While testing our application running on libkqueue we have found memory leak using
clang -fsanitize=address
.We are using
libkqueue-2.3.1
but it seems to be failing also on older versions.For reproduce just init kqueue file descriptor. Code to reproduce:
main.c