Fixed compile issues on WIN32