fix concurrency issue with LockFile