This is the build failure of GNAT 4.6.x on Windows. The patch was posted in September of last year: http://gcc.gnu.org/ml/gcc/2010-09/msg00228.html
Applied on the mainline and 4.6 branch. 2011-07-14 Florian Weimer <f...@deneb.enyo.de> PR ada/48711 * g-socthi-mingw.adb (Fill): Guard against invalid MSG_WAITALL. -- Eric Botcazou
Index: g-socthi-mingw.adb =================================================================== --- g-socthi-mingw.adb (revision 176261) +++ g-socthi-mingw.adb (working copy) @@ -277,7 +277,8 @@ package body GNAT.Sockets.Thin is use type C.size_t; Fill : constant Boolean := - (C.unsigned (Flags) and SOSC.MSG_WAITALL) /= 0; + SOSC.MSG_WAITALL /= -1 + and then (C.unsigned (Flags) and SOSC.MSG_WAITALL) /= 0; -- Is the MSG_WAITALL flag set? If so we need to fully fill all vectors Res : C.int;