Fixed UnauthorizedAccessException in combination with TortoiseGit/TortoiseHg