probably fixed memory leak