Fixed other memory leaks