diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2018-12-01 21:39:30 +0100 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2018-12-01 21:42:12 +0100 |
commit | fc493bc9e6fe8ecdd00f79b9a8a3d4675137a602 (patch) | |
tree | 75ea15d71527fceb2b1511620420960fbbe439c1 /sysdeps/htl/pt-mutex-init.c | |
parent | 6310e6be9b7c322d56a45729b3ebcd22e26dd0c2 (diff) | |
download | glibc-fc493bc9e6fe8ecdd00f79b9a8a3d4675137a602.tar.gz glibc-fc493bc9e6fe8ecdd00f79b9a8a3d4675137a602.tar.xz glibc-fc493bc9e6fe8ecdd00f79b9a8a3d4675137a602.zip |
htl: Fix comparing attr with default values
Fortunately we were previously only missing an optimization. Thanks dcb <dcb314@hotmail.com> for the report [BZ #23032] * sysdeps/htl/pt-barrier-init.c (pthread_barrier_init): Fix comparing attr with __pthread_default_barrierattr. * sysdeps/htl/pt-cond-init.c (__pthread_cond_init): Fix comparing attr with __pthread_default_condattr. * sysdeps/htl/pt-mutex-init.c (_pthread_mutex_init): Fix comparing attr with __pthread_default_mutexattr. * sysdeps/htl/pt-rwlock-init.c (_pthread_rwlock_init): Fix comparing attr with __pthread_default_rwlockattr.
Diffstat (limited to 'sysdeps/htl/pt-mutex-init.c')
-rw-r--r-- | sysdeps/htl/pt-mutex-init.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/htl/pt-mutex-init.c b/sysdeps/htl/pt-mutex-init.c index 664fd607c1..813b976e62 100644 --- a/sysdeps/htl/pt-mutex-init.c +++ b/sysdeps/htl/pt-mutex-init.c @@ -29,7 +29,7 @@ _pthread_mutex_init (pthread_mutex_t *mutex, const pthread_mutexattr_t *attr) *mutex = (pthread_mutex_t) __PTHREAD_MUTEX_INITIALIZER; if (attr == NULL - || memcmp (attr, &__pthread_default_mutexattr, sizeof (*attr) == 0)) + || memcmp (attr, &__pthread_default_mutexattr, sizeof (*attr)) == 0) /* The default attributes. */ return 0; |