Quoting Microsoft: The Winsock2.h header file internally includes core elements from the Windows.h header file, so there is not usually an #include line for the Windows.h
The inclusion does lead to cases where WIN32_LEAN_AND_MEAN was redefined, and a warning was generated
Looks like you left out some instances. Was that intentional? How's this updated patch?
(Also, what platform are you getting warnings on? I'm not seeing any here with msvc or mingw.)