2017-09-08 23:51:46 +02:00
|
|
|
--- src/cdo_pthread.cc.orig 2017-07-03 08:59:29 UTC
|
|
|
|
+++ src/cdo_pthread.cc
|
2017-02-16 17:45:27 +01:00
|
|
|
@@ -32,8 +32,10 @@ void print_pthread_info()
|
2006-12-04 17:00:06 +01:00
|
|
|
{
|
2017-02-16 17:45:27 +01:00
|
|
|
#if defined(HAVE_LIBPTHREAD)
|
2006-12-04 17:00:06 +01:00
|
|
|
pthread_attr_t attr;
|
2007-04-10 05:09:55 +02:00
|
|
|
+#if defined (PTHREAD_MUTEXATTR_CONDATTR)
|
2006-12-04 17:00:06 +01:00
|
|
|
pthread_mutexattr_t m_attr;
|
|
|
|
pthread_condattr_t c_attr;
|
2006-12-18 06:41:16 +01:00
|
|
|
+#endif
|
2006-12-04 17:00:06 +01:00
|
|
|
|
2017-02-16 17:45:27 +01:00
|
|
|
#if defined(PTHREAD_KEYS_MAX)
|
2006-12-04 17:00:06 +01:00
|
|
|
fprintf(stderr, "PTHREAD_KEYS_MAX = %d\n", PTHREAD_KEYS_MAX);
|
2017-02-16 17:45:27 +01:00
|
|
|
@@ -54,6 +56,7 @@ void print_pthread_info()
|
2006-12-04 17:00:06 +01:00
|
|
|
print_pthread_attr("Default pthread attr", &attr);
|
|
|
|
pthread_attr_destroy(&attr);
|
|
|
|
|
2007-04-10 05:09:55 +02:00
|
|
|
+#if defined (PTHREAD_MUTEXATTR_CONDATTR)
|
2006-12-04 17:00:06 +01:00
|
|
|
pthread_mutexattr_init(&m_attr);
|
|
|
|
print_pthread_mutexattr("Default pthread mutexattr", &m_attr);
|
|
|
|
pthread_mutexattr_destroy(&m_attr);
|
2017-02-16 17:45:27 +01:00
|
|
|
@@ -61,6 +64,7 @@ void print_pthread_info()
|
2006-12-04 17:00:06 +01:00
|
|
|
pthread_condattr_init(&c_attr);
|
|
|
|
print_pthread_condattr("Default pthread condattr ", &c_attr);
|
|
|
|
pthread_condattr_destroy(&c_attr);
|
2006-12-18 06:41:16 +01:00
|
|
|
+#endif
|
2006-12-04 17:00:06 +01:00
|
|
|
|
|
|
|
fprintf(stderr, "\n");
|
|
|
|
#endif
|