Merge pull request #8642 from JoelLinn/fix-mingw-bswap

Fix MinGW compilation