From: Nick Mathewson Date: Mon, 18 Jul 2011 01:48:38 +0000 (-0400) Subject: Fix a warning in evutil_rand when building with threads disabled X-Git-Tag: release-2.0.13-stable~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=00a7a0e4781bd903551f506e4b18309c0f6a71a7;p=libevent Fix a warning in evutil_rand when building with threads disabled --- diff --git a/evutil_rand.c b/evutil_rand.c index 82ea115e..27b505d6 100644 --- a/evutil_rand.c +++ b/evutil_rand.c @@ -89,7 +89,9 @@ arc4random_buf(void *buf, size_t n) #define ARC4RANDOM_EXPORT static #define _ARC4_LOCK() EVLOCK_LOCK(arc4rand_lock, 0) #define _ARC4_UNLOCK() EVLOCK_UNLOCK(arc4rand_lock, 0) +#ifndef _EVENT_DISABLE_THREAD_SUPPORT static void *arc4rand_lock; +#endif #define ARC4RANDOM_UINT32 ev_uint32_t #define ARC4RANDOM_NOSTIR