From 7296a3704ce7fd24e179b9ce7fd5b5daf5a3e920 Mon Sep 17 00:00:00 2001 From: hackbard Date: Thu, 30 Sep 2004 18:01:38 +0000 Subject: [PATCH] more printfs --- random.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/random.c b/random.c index 30a7fab..cb3e900 100644 --- a/random.c +++ b/random.c @@ -55,6 +55,9 @@ u32 get_rand(u32 max) { if(c_ptr>=b_ptr+BUFSIZE) { +#ifdef MORE_PRINTF + printf("getting another %d bytes of random data ...",BUFSIZE); +#endif if(read(rand_fd,b_ptr,BUFSIZE*sizeof(u32)) assume random file, end reached */ @@ -63,6 +66,9 @@ u32 get_rand(u32 max) read(rand_fd,b_ptr,BUFSIZE*sizeof(u32)); } c_ptr=b_ptr; +#ifdef MORE_PRINTF + printf(" done\n"); +#endif } return((u32)(*(c_ptr++)*(max*1.0/((long long unsigned int)URAND_MAX+1)))); -- 2.20.1