kanade2010 / cpp11_muduo

c++11 implementation of muduo net lib and muduo asynclogging.
32 stars 12 forks source link

少了#else? #2

Open fujingyuan opened 1 year ago

fujingyuan commented 1 year ago
  sock = socket(family, SOCK_STREAM|SOCK_CLOEXEC, 0);
  if (sock != -1 || errno != EINVAL) return sock;
  // An "errno" of EINVAL likely means that the system wasn't happy with the SOCK_CLOEXEC; fall through and try again without it:
#endif

  sock = socket(family, SOCK_STREAM, 0);