diff options
author | Sebastian Hahn <sebastian@torproject.org> | 2012-06-01 05:23:29 +0200 |
---|---|---|
committer | Sebastian Hahn <sebastian@torproject.org> | 2012-06-01 05:23:29 +0200 |
commit | fcec3e80c43722954ee4f63150b5eb1a6343f06e (patch) | |
tree | 8e0eca660c95b9facdd8fc986c38cf20fb5008d6 /evutil_rand.c | |
parent | bff5f9407341030c77a29fc1c398083ccdb4e277 (diff) | |
download | libevent-fcec3e80c43722954ee4f63150b5eb1a6343f06e.tar.gz |
Correctly check for arc4random_buf
Apparently it's necssary to do an explicit comparison with NULL here.
This also gets rid of a compile warning
Diffstat (limited to 'evutil_rand.c')
-rw-r--r-- | evutil_rand.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/evutil_rand.c b/evutil_rand.c index e2bf605f..b66d88b4 100644 --- a/evutil_rand.c +++ b/evutil_rand.c @@ -70,7 +70,7 @@ ev_arc4random_buf(void *buf, size_t n) * and fall back otherwise. (OSX does this using some linker * trickery.) */ - if (arc4random_buf) { + if (arc4random_buf != NULL) { return arc4random_buf(buf, n); } #endif |