quick memory leak fix