use strict; use warnings; use Inline C => <<'END_OF_C'; #define _GNU_SOURCE void foo() { char *s; asprintf(&s, "%s", "foo"); free(s); } END_OF_C foo(); __END__ Free to wrong pool 6334e0 not 8c00140021160806 at asprintf.pl line 13.