2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-30 14:07:59 +00:00

allow blocking when priming the pseudorandom generator

This commit is contained in:
Michael Graff
2000-06-12 18:28:25 +00:00
parent 8422b3823f
commit 8fdd9c31b9

View File

@@ -545,7 +545,10 @@ isc_entropy_getdata(isc_entropy_t *ent, void *data, unsigned int length,
* If we've extracted half our pool size in bits
* since the last refresh, try to refresh here.
*/
fillpool(ent, 0, ISC_FALSE);
if (ent->initialized < 20)
fillpool(ent, 20, blocking);
else
fillpool(ent, 0, ISC_FALSE);
/*
* If we've not initialized with enough good random