Initialize the mutex before making us of it from many threads. Prevents
authoranton <anton@openbsd.org>
Sun, 3 Apr 2022 16:52:50 +0000 (16:52 +0000)
committeranton <anton@openbsd.org>
Sun, 3 Apr 2022 16:52:50 +0000 (16:52 +0000)
commit58ad6127dadf5d2a45be99d5f434a49eb66b1279
treeabab929ec4a1642dfdae6a4273f16260e98e33b3
parent573411a3dbe750dd96e9fbc71e8058d09fbb1734
Initialize the mutex before making us of it from many threads. Prevents
a race in which one thread is currently initializing the mutex which is
not an atomic operation whereas another thread tries to use it too
early.

With and ok schwarze@
regress/lib/libc/locale/uselocale/uselocale.c