fix memory crap