summaryrefslogtreecommitdiff
path: root/lib/glthread
diff options
context:
space:
mode:
Diffstat (limited to 'lib/glthread')
-rw-r--r--lib/glthread/lock.c2
-rw-r--r--lib/glthread/lock.h12
-rw-r--r--lib/glthread/threadlib.c2
3 files changed, 11 insertions, 5 deletions
diff --git a/lib/glthread/lock.c b/lib/glthread/lock.c
index df05dbc..9e14891 100644
--- a/lib/glthread/lock.c
+++ b/lib/glthread/lock.c
@@ -1,5 +1,5 @@
/* Locking in multithreaded situations.
- Copyright (C) 2005-2017 Free Software Foundation, Inc.
+ Copyright (C) 2005-2018 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or
modify it under the terms of either:
diff --git a/lib/glthread/lock.h b/lib/glthread/lock.h
index 0628555..2d8d5ab 100644
--- a/lib/glthread/lock.h
+++ b/lib/glthread/lock.h
@@ -1,5 +1,5 @@
/* Locking in multithreaded situations.
- Copyright (C) 2005-2017 Free Software Foundation, Inc.
+ Copyright (C) 2005-2018 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or
modify it under the terms of either:
@@ -158,8 +158,14 @@ extern int glthread_in_use (void);
# endif
# if !PTHREAD_IN_USE_DETECTION_HARD
-# pragma weak pthread_cancel
-# define pthread_in_use() (pthread_cancel != NULL)
+ /* Considering all platforms with USE_POSIX_THREADS_WEAK, only few symbols
+ can be used to determine whether libpthread is in use. These are:
+ pthread_mutexattr_gettype
+ pthread_rwlockattr_destroy
+ pthread_rwlockattr_init
+ */
+# pragma weak pthread_mutexattr_gettype
+# define pthread_in_use() (pthread_mutexattr_gettype != NULL)
# endif
# else
diff --git a/lib/glthread/threadlib.c b/lib/glthread/threadlib.c
index 82b8861..3534b61 100644
--- a/lib/glthread/threadlib.c
+++ b/lib/glthread/threadlib.c
@@ -1,5 +1,5 @@
/* Multithreading primitives.
- Copyright (C) 2005-2017 Free Software Foundation, Inc.
+ Copyright (C) 2005-2018 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or
modify it under the terms of either: