fix compile errors on linux
authorFelix Fietkau <nbd@openwrt.org>
Thu, 3 Jan 2013 12:50:59 +0000 (13:50 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Thu, 3 Jan 2013 12:51:02 +0000 (13:51 +0100)
auth.c
main.c

diff --git a/auth.c b/auth.c
index c27488f..afab2c0 100644 (file)
--- a/auth.c
+++ b/auth.c
@@ -17,6 +17,8 @@
  *  limitations under the License.
  */
 
+#define _GNU_SOURCE
+#define _XOPEN_SOURCE  700
 #include "uhttpd.h"
 
 static LIST_HEAD(auth_realms);
diff --git a/main.c b/main.c
index 100e285..26dc55c 100644 (file)
--- a/main.c
+++ b/main.c
@@ -17,6 +17,8 @@
  *  limitations under the License.
  */
 
+#define _GNU_SOURCE
+#define _XOPEN_SOURCE  700
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
@@ -25,6 +27,7 @@
 #include <errno.h>
 #include <netdb.h>
 #include <signal.h>
+#include <unistd.h>
 
 #include <libubox/usock.h>