diff options
author | 2014-07-16 00:18:54 +0000 | |
---|---|---|
committer | 2014-07-16 00:18:54 +0000 | |
commit | f32ced12d1a21fcb47a27138943a8e3c30d26bd7 (patch) | |
tree | 10cdf36edbbc506fc1da324880cad8c0a2e35ee9 /lib/libc/crypt/arc4random.c | |
parent | added handler for an atfork hook from kettenis@ (diff) | |
download | wireguard-openbsd-f32ced12d1a21fcb47a27138943a8e3c30d26bd7.tar.xz wireguard-openbsd-f32ced12d1a21fcb47a27138943a8e3c30d26bd7.zip |
#ifdef wrap the _rs_forkhandler
Diffstat (limited to 'lib/libc/crypt/arc4random.c')
-rw-r--r-- | lib/libc/crypt/arc4random.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libc/crypt/arc4random.c b/lib/libc/crypt/arc4random.c index 37b1ad77c18..3b7f34faed5 100644 --- a/lib/libc/crypt/arc4random.c +++ b/lib/libc/crypt/arc4random.c @@ -1,4 +1,4 @@ -/* $OpenBSD: arc4random.c,v 1.44 2014/07/16 00:15:35 bcook Exp $ */ +/* $OpenBSD: arc4random.c,v 1.45 2014/07/16 00:18:54 deraadt Exp $ */ /* * Copyright (c) 1996, David Mazieres <dm@uun.org> @@ -65,12 +65,14 @@ static struct { static inline void _rs_rekey(u_char *dat, size_t datlen); +#ifndef MAP_INHERIT_ZERO static inline void _rs_forkhandler(void) { if (rs) rs->rs_count = 0; } +#endif /* MAP_INHERIT_ZERO */ static inline void _rs_init(u_char *buf, size_t n) |