Improve 76bf791c2a990eebe3b1d7620bd002a5999415b0

Puts the fix where it really should be in replace_win32_incompat.
Merge pull request #321 from Sophist-UK/sophist_improve_76bf791c2a990eebe3b1d7620bd002a5999415b0

Improve 76bf791