task memory leak fixed