]> arthur.barton.de Git - netdata.git/commitdiff
fix for compiling in RHEL 5.x; fixes #911
authorCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Wed, 7 Sep 2016 17:39:22 +0000 (20:39 +0300)
committerCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Wed, 7 Sep 2016 17:39:22 +0000 (20:39 +0300)
src/web_server.c

index a9beff88c26db7b68832c9db5d45b1c45cda764d..71781cdb631cac54602254a5adb8bac70a2f39ff 100644 (file)
@@ -39,10 +39,12 @@ int accept4(int sock, struct sockaddr *addr, socklen_t *addrlen, int flags) {
     }
 
 #ifdef SOCK_CLOEXEC
+#ifdef O_CLOEXEC
     if (flags & SOCK_CLOEXEC) {
         newflags |= O_CLOEXEC;
         flags &= ~SOCK_CLOEXEC;
     }
+#endif
 #endif
 
     if (flags) {