Cleaned up Win32 calls