Fix windows

Fix some issues on 32-bit windows.

Closes #73 #70