diff random.c @ 446:2cd2edfa11ee

Just use /dev/urandom since that's what everyone ends up using anyway. Make -u a nop.
author Matt Johnston <matt@ucc.asn.au>
date Thu, 19 Jul 2007 15:47:32 +0000
parents d82a2a44c684
children c1e9c81d1d27 76097ec1a29a
line wrap: on
line diff
--- a/random.c	Thu Jul 19 14:08:24 2007 +0000
+++ b/random.c	Thu Jul 19 15:47:32 2007 +0000
@@ -27,13 +27,6 @@
 #include "dbutil.h"
 #include "bignum.h"
 
-#ifdef DROPBEAR_RANDOM_DEV
-const char* random_dev = DROPBEAR_RANDOM_DEV;	
-#else
-const char* random_dev = NULL;
-#endif
-
-
 static int donerandinit = 0;
 
 /* this is used to generate unique output from the same hashpool */
@@ -69,9 +62,9 @@
 #endif
 
 #ifdef DROPBEAR_RANDOM_DEV
-	readfd = open(random_dev, O_RDONLY);		
+	readfd = open(DROPBEAR_RANDOM_DEV, O_RDONLY);
 	if (readfd < 0) {
-		dropbear_exit("couldn't open %s", random_dev);
+		dropbear_exit("couldn't open random device");
 	}
 #endif