Solved some leaks