uhttpd: protect tcp receive operations with select, make tcp keep-alive optional...
[openwrt/staging/dedeckeh.git] / package / uhttpd / src / uhttpd.h
index 78cca7b3b2a0e27689da21294d883d400415d94f..ff058d62bff3e214e4dee0e5c8cb5e35a63050e7 100644 (file)
@@ -28,6 +28,7 @@
 #include <sys/select.h>
 #include <sys/wait.h>
 #include <netinet/in.h>
+#include <netinet/tcp.h>
 #include <arpa/inet.h>
 #include <linux/limits.h>
 #include <netdb.h>
 #include <openssl/ssl.h>
 #endif
 
+/* uClibc... */
+#ifndef SOL_TCP
+#define SOL_TCP        6
+#endif
+
 
 #define UH_LIMIT_MSGHEAD       4096
 #define UH_LIMIT_HEADERS       64
@@ -69,6 +75,7 @@ struct config {
        int no_dirlists;
        int network_timeout;
        int rfc1918_filter;
+       int tcp_keepalive;
 #ifdef HAVE_CGI
        char *cgi_prefix;
 #endif