Valgrind clean up of memory leaks.

Added valgrind piping support to runner file. Will need valgrind installed locally to run.