Add finalize_rand()

pull/25/head
Dustin Laurence 10 years ago
parent fb747384a0
commit 661751ab4b

@ -33,6 +33,12 @@ void init_rand(void)
f = fopen("/dev/urandom", "r");
}
void finalize_rand(void)
{
fclose(f);
f = NULL;
}
uint32_t random32(void)
{
uint32_t r;

@ -27,6 +27,7 @@
#include <stdint.h>
void init_rand(void);
void finalize_rand(void);
uint32_t random32(void);
void random_buffer(uint8_t *buf, size_t len);

Loading…
Cancel
Save