windows: incorrect check for SOCKET_ERROR
getsockopt() return 0 or -1, with !getsockopt() return 0 or 1