Restore working directory before final reset