mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-24 16:49:35 -05:00
- Fix crash on multiple thread random usage on systems without
arc4random. git-svn-id: file:///svn/unbound/trunk@3277 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
02b6373a7e
commit
58542119a2
2 changed files with 7 additions and 1 deletions
|
|
@ -53,8 +53,10 @@ static int arc4lockinit = 0;
|
||||||
|
|
||||||
void _ARC4_LOCK(void)
|
void _ARC4_LOCK(void)
|
||||||
{
|
{
|
||||||
if(!arc4lockinit)
|
if(!arc4lockinit) {
|
||||||
|
arc4lockinit = 1;
|
||||||
lock_quick_init(&arc4lock);
|
lock_quick_init(&arc4lock);
|
||||||
|
}
|
||||||
lock_quick_lock(&arc4lock);
|
lock_quick_lock(&arc4lock);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,7 @@
|
||||||
|
21 November 2014: Wouter
|
||||||
|
- Fix crash on multiple thread random usage on systems without
|
||||||
|
arc4random.
|
||||||
|
|
||||||
20 November 2014: Wouter
|
20 November 2014: Wouter
|
||||||
- fix compat/getentropy_win.c check if CryptGenRandom works and no
|
- fix compat/getentropy_win.c check if CryptGenRandom works and no
|
||||||
immediate exit on windows.
|
immediate exit on windows.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue