Memory clearing after finish.