cmFileLock: Fix implementation on Windows

Fixes: #26428
3 files changed