fix mingw32/mingw64 compiling

Fix compile error on mingw32/mingw64 platform