On Fri, Apr 09, 2021 at 06:49:39PM +0200, Andrzej Hunt wrote: > > ==63105== 40 bytes in 1 blocks are possibly lost in loss record 38 of 142 > > ==63105== at 0x4C31B0F: malloc (in > > /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) > > ==63105== by 0x34013A: do_xmalloc (wrapper.c:41) > > ==63105== by 0x355BB5: chdir_notify_register (chdir-notify.c:18) > [...] > > These are a bit odd: chdir_notify_register() is attaching the newly > allocated memory to a static list (chdir_notify_entries), and I can't see > any obvious reason why this would leak (but maybe valgrind doesn't like > static pointers)? Either way, this doesn't seem to be anywhere near the > regex code. These "possibly lost" are false positives; there's more discussion in this thread: https://lore.kernel.org/git/20201117002435.GA13516@xxxxxxxxxxxxxxxxxxxxxxx/ -Peff