Fixed some leaks.