commit 391975361814e6d24e674feeea1b92d1f6388eb7
parent 95cebdae461e6da9a0f433a0ad212c0363aea10f
Author: Christian Grothoff <grothoff@gnunet.org>
Date: Sun, 16 Aug 2026 08:55:27 +0200
improve portability
Diffstat:
4 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/util/secmod_common.c b/src/util/secmod_common.c
@@ -40,7 +40,7 @@ struct TES_Client *TES_clients_tail;
/**
* Lock for the client queue.
*/
-pthread_mutex_t TES_clients_lock;
+pthread_mutex_t TES_clients_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Private key of this security module. Used to sign denomination key
diff --git a/src/util/secmod_cs.c b/src/util/secmod_cs.c
@@ -321,7 +321,7 @@ static struct Worker *worker_tail;
/**
* Lock for manipulating the worker DLL.
*/
-static pthread_mutex_t worker_lock;
+static pthread_mutex_t worker_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Total number of workers that were started.
@@ -379,7 +379,7 @@ static struct GNUNET_SCHEDULER_Task *keygen_task;
/**
* Lock for the keys queue.
*/
-static pthread_mutex_t keys_lock;
+static pthread_mutex_t keys_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Current key generation.
diff --git a/src/util/secmod_eddsa.c b/src/util/secmod_eddsa.c
@@ -144,7 +144,7 @@ static struct GNUNET_SCHEDULER_Task *keygen_task;
/**
* Lock for the keys queue.
*/
-static pthread_mutex_t keys_lock;
+static pthread_mutex_t keys_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Current key generation.
diff --git a/src/util/secmod_rsa.c b/src/util/secmod_rsa.c
@@ -288,7 +288,7 @@ static struct Worker *worker_tail;
/**
* Lock for manipulating the worker DLL.
*/
-static pthread_mutex_t worker_lock;
+static pthread_mutex_t worker_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Total number of workers that were started.
@@ -346,7 +346,7 @@ static struct GNUNET_SCHEDULER_Task *keygen_task;
/**
* Lock for the keys queue.
*/
-static pthread_mutex_t keys_lock;
+static pthread_mutex_t keys_lock = PTHREAD_MUTEX_INITIALIZER;
/**
* Current key generation.