about summary refs log tree commit diff
path: root/nptl/pthread_rwlock_timedwrlock.c
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2021-05-03 09:10:57 +0200
committerFlorian Weimer <fweimer@redhat.com>2021-05-03 09:18:12 +0200
commite7d2d48e560a2091e2a03c527c333cd7b5618b25 (patch)
tree133ae917524140c08d64b3b81029192970f3136d /nptl/pthread_rwlock_timedwrlock.c
parent2392feb17188fed30bc16fd032e0a43e022b8ead (diff)
downloadglibc-e7d2d48e560a2091e2a03c527c333cd7b5618b25.tar.gz
glibc-e7d2d48e560a2091e2a03c527c333cd7b5618b25.tar.xz
glibc-e7d2d48e560a2091e2a03c527c333cd7b5618b25.zip
nptl: Move pthread_rwlock_timedwrlock into libc
The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Carlos O'Donell <carlos@redhat.com>
Diffstat (limited to 'nptl/pthread_rwlock_timedwrlock.c')
-rw-r--r--nptl/pthread_rwlock_timedwrlock.c23
1 files changed, 16 insertions, 7 deletions
diff --git a/nptl/pthread_rwlock_timedwrlock.c b/nptl/pthread_rwlock_timedwrlock.c
index 14470e3f07..e660a544cd 100644
--- a/nptl/pthread_rwlock_timedwrlock.c
+++ b/nptl/pthread_rwlock_timedwrlock.c
@@ -17,25 +17,34 @@
    <https://www.gnu.org/licenses/>.  */
 
 #include "pthread_rwlock_common.c"
+#include <shlib-compat.h>
 
 /* See pthread_rwlock_common.c.  */
 int
-__pthread_rwlock_timedwrlock64 (pthread_rwlock_t *rwlock,
-                                const struct __timespec64 *abstime)
+___pthread_rwlock_timedwrlock64 (pthread_rwlock_t *rwlock,
+				 const struct __timespec64 *abstime)
 {
   return __pthread_rwlock_wrlock_full64 (rwlock, CLOCK_REALTIME, abstime);
 }
 
-#if __TIMESIZE != 64
-libpthread_hidden_def (__pthread_rwlock_timedwrlock64)
+#if __TIMESIZE == 64
+strong_alias (___pthread_rwlock_timedwrlock64, ___pthread_rwlock_timedwrlock)
+#else /* __TIMESPEC64 != 64 */
+libc_hidden_ver (___pthread_rwlock_timedwrlock64,
+		 __pthread_rwlock_timedwrlock64)
 
 int
-__pthread_rwlock_timedwrlock (pthread_rwlock_t *rwlock,
-                              const struct timespec *abstime)
+___pthread_rwlock_timedwrlock (pthread_rwlock_t *rwlock,
+			       const struct timespec *abstime)
 {
   struct __timespec64 ts64 = valid_timespec_to_timespec64 (*abstime);
 
   return __pthread_rwlock_timedwrlock64 (rwlock, &ts64);
 }
+#endif /* __TIMESPEC64 != 64 */
+versioned_symbol (libc, ___pthread_rwlock_timedwrlock,
+		  pthread_rwlock_timedwrlock, GLIBC_2_34);
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_2, GLIBC_2_34)
+compat_symbol (libpthread, ___pthread_rwlock_timedwrlock,
+	       pthread_rwlock_timedwrlock, GLIBC_2_2);
 #endif
-weak_alias (__pthread_rwlock_timedwrlock, pthread_rwlock_timedwrlock)