Fix ztimeout casts for MSVC
Merge pull request #688 from twhittock/ztimeout-build-msvc

Fix ztimeout casts for MSVC