diff --git a/ChangeLog b/ChangeLog index 2eeeabf2ad..9cc8d65ca8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2018-06-26 Patsy Franklin + + * nptl/sem_open.c [!__HAVE_64B_ATOMICS] (sem_open): Don't update pad. + (sem_open): Set sem.newsem.pad to zero for valgrind. + 2018-06-26 Adhemerval Zanella [BZ #20251] diff --git a/nptl/sem_open.c b/nptl/sem_open.c index 1d7f142134..c5389f6873 100644 --- a/nptl/sem_open.c +++ b/nptl/sem_open.c @@ -215,10 +215,11 @@ sem_open (const char *name, int oflag, ...) sem.newsem.data = value; #else sem.newsem.value = value << SEM_VALUE_SHIFT; - /* pad is used as a mutex on pre-v9 sparc and ignored otherwise. */ - sem.newsem.pad = 0; sem.newsem.nwaiters = 0; #endif + /* pad is used as a mutex on pre-v9 sparc and ignored otherwise. */ + sem.newsem.pad = 0; + /* This always is a shared semaphore. */ sem.newsem.private = FUTEX_SHARED;