try to fix memory leak