X-Git-Url: https://hackdaworld.org/gitweb/?p=physik%2Fmorpheus.git;a=blobdiff_plain;f=random.c;h=81a066752eb3d1de6fa0f71ef72c9b9e0c8b5c42;hp=c81dffa5ea3772717f5d9d970d68c5c9be523631;hb=10f0b7a7cb49dbd9cbeef240c7eb814cf822596c;hpb=2fc464b1e03445cd60e9305dc9b75471ebdb04af diff --git a/random.c b/random.c index c81dffa..81a0667 100644 --- a/random.c +++ b/random.c @@ -5,6 +5,7 @@ #include #include +#include #include #include #include @@ -25,7 +26,7 @@ u32 rand_get(u32 max) printfd("debug: reading new random bytes\n"); if(read(random_fd,rand_buf,RAND_BUF_SIZE)!=RAND_BUF_SIZE) { - if(!strcmp(random_file,"")) + if(strcmp(random_file,"")) { puts("random file end, starting over ..."); lseek(random_fd,0,SEEK_SET);