From f6d35a70a88422e92cf2b8e80cb6fe335f2029d2 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Tue, 27 Sep 2011 17:52:54 +1000 Subject: [PATCH] Must initialise the donorpool mutex or it fails on windows. --- main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/main.c b/main.c index a045af6a..4d0145f9 100644 --- a/main.c +++ b/main.c @@ -5583,6 +5583,8 @@ int main (int argc, char *argv[]) if (!get_dondata(&donationpool.rpc_url, &donationpool.rpc_userpass)) opt_donation = 0.0; else { + if (unlikely(pthread_mutex_init(&donationpool.pool_lock, NULL))) + quit (1, "Failed to pthread_mutex_init in add donpool"); donationpool.enabled = true; donationpool.pool_no = MAX_POOLS; if (!pool_active(&donationpool, false))