add free for malloc with valgrind