Boost.Thread triggers warning C4103 in Microsoft Visual Studio
Got a whole mess of warnings when I moved some of my includes around, particularly this one: #include <boost/thread.hpp>
abi_prefix.hpp(19) : warning C4103: 'd:\\boost\\boost_1_38_0\\boost\\config\\abi_prefix.hpp' : alignment changed after including header, may be due to missing #pragma pack(pop)
Some experimentation reveals that including thread.hpp
before winsock2.h
triggers all these warnings. The simple solution is to just move #include <boost/thread.hpp>
down below #include <winsock2.h>
.