aboutsummaryrefslogtreecommitdiffstats
path: root/cipher/random.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>1997-11-26 22:02:28 +0000
committerWerner Koch <[email protected]>1997-11-26 22:02:28 +0000
commit9479cf7e24abf0998ebbc083e28741038d535b68 (patch)
tree987fa4ffc48db5e94342901fa064f41bf1a7a2da /cipher/random.c
parentadded assembler modules (diff)
downloadgnupg-9479cf7e24abf0998ebbc083e28741038d535b68.tar.gz
gnupg-9479cf7e24abf0998ebbc083e28741038d535b68.zip
How with some assembly support
Diffstat (limited to 'cipher/random.c')
-rw-r--r--cipher/random.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/cipher/random.c b/cipher/random.c
index 73a9a3ebf..b4abbdda9 100644
--- a/cipher/random.c
+++ b/cipher/random.c
@@ -43,6 +43,7 @@ randomize_buffer( byte *buffer, size_t length, int level )
if( level == 2 )
level = 1; /* 2 is much too slow */
+ /* FIXME: do a stat and check that we have the correct device numbers*/
fp = fopen(level < 2? "/dev/urandom":"/dev/random", "r");
if( !fp )
log_fatal("can't open random device: %s\n", strerror(errno) );