]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Fix linux compilation (pipe2 needs _GNU_SOURCE)
authorNick Mathewson <nickm@torproject.org>
Thu, 26 Sep 2013 03:25:02 +0000 (23:25 -0400)
committerNick Mathewson <nickm@torproject.org>
Wed, 14 Jan 2015 16:09:51 +0000 (11:09 -0500)
src/common/compat_threads.c

index 648eaa2d80b8e1d0a0b8bfe22eec1dfe9ad7bdab..ba48eb4d1fcd711ba8cf07043ae0a25e49af5f09 100644 (file)
@@ -3,6 +3,8 @@
  * Copyright (c) 2007-2015, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
+#define _GNU_SOURCE
+
 #include "orconfig.h"
 #define _GNU_SOURCE
 #include <stdlib.h>
 #ifdef HAVE_SYS_EVENTFD_H
 #include <sys/eventfd.h>
 #endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
 #ifdef HAVE_FCNTL_H
 #include <fcntl.h>
 #endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
 
 /** Return a newly allocated, ready-for-use mutex. */
 tor_mutex_t *