[FIX] Valgrind errors