fix some warnings on mingw