Hacks to prevent error and warnings on windows.