diff options
author | Damien Miller <djm@mindrot.org> | 2013-11-07 13:28:16 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2013-11-07 13:28:16 +1100 |
commit | df8b030b15fcec7baf38ec7944f309f9ca8cc9a7 (patch) | |
tree | 70ae8223d81ef4a7692be0eb295ad5cf1b98aee7 /defines.h | |
parent | a6fd1d3c38a562709374a70fa76423859160aa90 (diff) | |
download | openssh-git-df8b030b15fcec7baf38ec7944f309f9ca8cc9a7.tar.gz |
- (djm) [configure.ac defines.h] Skip arc4random_stir() calls on platforms
that lack it but have arc4random_uniform()
Diffstat (limited to 'defines.h')
-rw-r--r-- | defines.h | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -25,7 +25,7 @@ #ifndef _DEFINES_H #define _DEFINES_H -/* $Id: defines.h,v 1.173 2013/11/03 07:43:55 dtucker Exp $ */ +/* $Id: defines.h,v 1.174 2013/11/07 02:28:16 djm Exp $ */ /* Constants */ @@ -810,4 +810,13 @@ struct winsize { # endif #endif +/* + * Platforms that have arc4random_uniform() and not arc4random_stir() + * shouldn't need the latter. + */ +#if defined(HAVE_ARC4RANDOM) && defined(HAVE_ARC4RANDOM_UNIFORM) && \ + !defined(HAVE_ARC4RANDOM_STIR) +# define arc4random_stir() +#endif + #endif /* _DEFINES_H */ |