Fix memory leak on exceptions