]> git.sesse.net Git - vlc/blobdiff - bin/rootwrap.c
access: archive: remove dead initialization
[vlc] / bin / rootwrap.c
index 1527406e2d2d8faa050f16653fe217db0bcd214f..37d88396faf55c5ec62db1bd187a5a0b8fe488b3 100644 (file)
@@ -34,7 +34,9 @@
 #include <sys/socket.h>
 #include <sys/uio.h>
 #include <sys/resource.h> /* getrlimit() */
+#ifdef RLIMIT_RTPRIO
 #include <sched.h>
+#endif
 #include <errno.h>
 #include <netinet/in.h>
 
@@ -170,6 +172,7 @@ static void rootprocess (int fd)
                 close (sock);
                 continue;
             }
+            close (sock);
         }
         send_err (fd, errno);
     }