FormatMessage for winsock errors

This uses FormatMessage to get string messages for winsock error codes, as we discussed on the mailing list.