From a43ff1f98e9b9814f858bccb11c174b418458491 Mon Sep 17 00:00:00 2001 From: Jaron Kent-Dobias Date: Wed, 10 Oct 2018 21:45:32 -0400 Subject: big rearrangement of files to make libraries and example (research) files clearer, and changed to c++ std lib random numbers --- lib/rand.c | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 lib/rand.c (limited to 'lib/rand.c') diff --git a/lib/rand.c b/lib/rand.c deleted file mode 100644 index 76f537d..0000000 --- a/lib/rand.c +++ /dev/null @@ -1,20 +0,0 @@ - -#include -#include - -unsigned long int rand_seed() { - /* - returns a random unsigned long integer read from the standard unix - pseudorandom device /dev/urandom - */ - - FILE *f = fopen("/dev/urandom", "r"); - assert(f != NULL); - - unsigned long int seed; - fread(&seed, sizeof(unsigned long int), 1, f); - - fclose(f); - - return seed; -} -- cgit v1.2.3-70-g09d2