aboutsummaryrefslogtreecommitdiff
path: root/src/tests
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2016-06-09 08:39:25 +0100
committerMichael Brown <mcb30@ipxe.org>2016-06-09 08:44:32 +0100
commit2c197517f2a82970ab6866e197f06a3099418324 (patch)
treee0ac644e77307e80f549a926b503e302b42b4e5d /src/tests
parentf6e8b800be5d8656aa2b10827cf7ea93cfcf5048 (diff)
downloadipxe-2c197517f2a82970ab6866e197f06a3099418324.zip
ipxe-2c197517f2a82970ab6866e197f06a3099418324.tar.gz
ipxe-2c197517f2a82970ab6866e197f06a3099418324.tar.bz2
[libc] Always use a non-zero seed for the (non-crypto) RNG
The non-cryptographic RNG implemented by random() has the property that a seed value of zero will result in a generated sequence of all-zero values. This situation can arise if currticks() returns zero at start of day. Work around this problem by falling back to a fixed non-zero seed if necessary. This has no effect on the separate DRBG used by cryptographic code. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/tests')
0 files changed, 0 insertions, 0 deletions