Made it possible to run VoterC in Valgrind, and fixed small leaks found.