Trying to fix memory bug.