runmodes: memory leaks
The memory leaks I'm reporting are preventing me from properly fuzzing Suricata 3.1.2 compiled with ASAN (as Suricata's AFL tutorial suggests "-fsanitize=address").
Some of those memory leaks do not affect real world usage, though.
I have attached the memory leaks reported by valgrind, which provides more details about the leaks.
Compilation options (It's basically from Suricata's AFL tutorial, but I didn't enable ASAN or AFL in order to run valgrind):
CFLAGS="-g -O0 -fno-omit-frame-pointer" ac_cv_func_realloc_0_nonnull=yes ac_cv_func_malloc_0_nonnull=yes ./configure --enable-nfqueue --enable-unittests --enable-profiling --prefix=/usr --sysconfdir=/etc --localstatedir=/var --enable-afl --disable-shared
The command I used for running Suricata:
$ valgrind --show-leak-kinds=all --leak-check=full -v ./src/suricata --afl-decoder-ppp /root/sample_traces/arp/arp-storm.pcap