repairs lock file