[Bug sanitizer/87840] LSAN misses self-refential shared_ptrs
marxin at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Nov 1 13:23:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87840
--- Comment #4 from Martin Liška <marxin at gcc dot gnu.org> ---
What about this:
$ cat empty.c
int main()
{
__builtin_malloc (12345);
return 0;
}
$ gcc -fsanitize=leak empty.c && ./a.out
=================================================================
==14721==ERROR: LeakSanitizer: detected memory leaks
Direct leak of 12345 byte(s) in 1 object(s) allocated from:
#0 0x7ffff713dbd8 in malloc (/usr/lib64/liblsan.so.0+0xfbd8)
#1 0x40111f in main (/home/marxin/Programming/testcases/a.out+0x40111f)
#2 0x7ffff6d90fea in __libc_start_main ../csu/libc-start.c:308
SUMMARY: LeakSanitizer: 12345 byte(s) leaked in 1 allocation(s).
More information about the Gcc-bugs
mailing list