Fix exit() by adding remove()