diff options
author | Werner Koch <wk@gnupg.org> | 1998-08-11 19:29:34 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 1998-08-11 19:29:34 +0200 |
commit | 3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0 (patch) | |
tree | dfff62df60f917addc9df4e83a1ed73e31041bab /cipher | |
parent | rel 0.3.3 (diff) | |
download | gnupg2-3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0.tar.xz gnupg2-3e0e8f884f1ed37e120beeb57aa7cd79e3c145a0.zip |
bug fix releaseV0-3-4
Diffstat (limited to 'cipher')
-rw-r--r-- | cipher/random.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cipher/random.c b/cipher/random.c index 29b82ee7c..e22f3d70c 100644 --- a/cipher/random.c +++ b/cipher/random.c @@ -124,6 +124,8 @@ get_random_bits( size_t nbits, int level, int secure ) byte *buf; size_t nbytes = (nbits+7)/8; + if( quick_test && level > 1 ) + level = 1; MASK_LEVEL(level); buf = secure && secure_alloc ? m_alloc_secure( nbytes ) : m_alloc( nbytes ); read_pool( buf, nbytes, level ); |