Fix executable checks on Windows.