util: always initialize the server log mutex 17/11717/10
authorMichael Meffie <mmeffie@sinenomine.net>
Wed, 4 Feb 2015 02:07:34 +0000 (21:07 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Mon, 25 Apr 2016 04:02:55 +0000 (00:02 -0400)
commit5e49cb98ac09b85d830f443a4c006d91764d2e35
tree1c5a6c300ce2de2234a4e99414fc69de787f8166
parent661f73beeb8cc61c24e1d53003d310e835c48a45
util: always initialize the server log mutex

Be sure to always initialize the server log mutex. Use pthread_once to
ensure the mutex is initialized only once.

Before this change the server log mutex was not properly initialized
with pthread_mutex_init when logging to the syslog.

Change-Id: Ief2ee6b373f7309bc05061f7413b6ff623b86e31
Reviewed-on: https://gerrit.openafs.org/11717
Reviewed-by: Chas Williams <3chas3@gmail.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
src/util/serverLog.c