try to eliminate several memory leaks
clean up the whole solution