[Mesa-dev] [PATCH 7/7] c11: Make TIME_UTC a conditional macro.

jfonseca at vmware.com jfonseca at vmware.com
Thu Jan 9 11:20:18 PST 2014


From: José Fonseca <jfonseca at vmware.com>

Some system headers already define it, so this prevents conflict.
---
 include/c11/threads.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/include/c11/threads.h b/include/c11/threads.h
index 678774c..4a4079d 100644
--- a/include/c11/threads.h
+++ b/include/c11/threads.h
@@ -10,6 +10,10 @@
 
 #include <time.h>
 
+#ifndef TIME_UTC
+#define TIME_UTC 1
+#endif
+
 #include "c99_compat.h" /* for `inline` */
 
 /*---------------------------- types ----------------------------*/
@@ -39,8 +43,6 @@ enum {
     thrd_nomem        // out of memory
 };
 
-enum { TIME_UTC = 1 };
-
 /*-------------------------- functions --------------------------*/
 
 #if defined(_WIN32) && !defined(__CYGWIN__)
-- 
1.8.3.2



More information about the mesa-dev mailing list