mp_rand_source(NULL) sets to platform random source
This commit is contained in:
parent
9e28ef9fa2
commit
56fb5e4a9a
@ -165,7 +165,7 @@ static int (*s_rand_source)(void *, size_t) = s_mp_rand_source_platform;
|
||||
|
||||
void mp_rand_source(int (*get)(void *out, size_t size))
|
||||
{
|
||||
s_rand_source = get;
|
||||
s_rand_source = get == NULL ? s_mp_rand_source_platform : get;
|
||||
}
|
||||
|
||||
/* makes a pseudo-random int of a given size */
|
||||
|
Loading…
Reference in New Issue
Block a user