Tighten behavior of _rs_allocate failure for portable arc4random implementations.
authorbcook <bcook@openbsd.org>
Thu, 30 Jun 2016 12:19:51 +0000 (12:19 +0000)
committerbcook <bcook@openbsd.org>
Thu, 30 Jun 2016 12:19:51 +0000 (12:19 +0000)
commit545f6b86ded87dbc7c6e5c5d540edde0277a0fcf
treef8660e919af76274389d869b62622148a3527864
parent81f0184cf44aca58c623858ff45e1cd13e9b4d8e
Tighten behavior of _rs_allocate failure for portable arc4random implementations.

In the event of a failure in _rs_allocate for rsx, we still have a reference to
freed memory for rs on return. Not a huge deal since we subsequently abort in
_rs_init, but it looks strange on its own.

ok deraadt@
14 files changed:
lib/libcrypto/arc4random/arc4random_aix.h
lib/libcrypto/arc4random/arc4random_freebsd.h
lib/libcrypto/arc4random/arc4random_hpux.h
lib/libcrypto/arc4random/arc4random_linux.h
lib/libcrypto/arc4random/arc4random_netbsd.h
lib/libcrypto/arc4random/arc4random_osx.h
lib/libcrypto/arc4random/arc4random_solaris.h
lib/libcrypto/crypto/arc4random_aix.h
lib/libcrypto/crypto/arc4random_freebsd.h
lib/libcrypto/crypto/arc4random_hpux.h
lib/libcrypto/crypto/arc4random_linux.h
lib/libcrypto/crypto/arc4random_netbsd.h
lib/libcrypto/crypto/arc4random_osx.h
lib/libcrypto/crypto/arc4random_solaris.h