diff options
author | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2013-12-29 16:35:49 +0100 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2013-12-29 16:35:49 +0100 |
commit | f6e5ff21c7d4486a9ec9ce5e0fd17177f8a5e98f (patch) | |
tree | 7c849ebe5c901f4d7035c1c14ba2b175a8f8fe50 /tests/rng-fork.c | |
parent | a07221176bc68df63dbac5178543d91f024bb9a0 (diff) | |
download | gnutls-f6e5ff21c7d4486a9ec9ce5e0fd17177f8a5e98f.tar.gz |
perform the iteration check on both rngs.
Diffstat (limited to 'tests/rng-fork.c')
-rw-r--r-- | tests/rng-fork.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/rng-fork.c b/tests/rng-fork.c index 4cf3246ef3..f0b32ce509 100644 --- a/tests/rng-fork.c +++ b/tests/rng-fork.c @@ -107,7 +107,15 @@ void doit(void) for (i = 0; i <= 65539; i++) { ret = gnutls_rnd(GNUTLS_RND_NONCE, buf1, sizeof(buf1)); if (ret < 0) { - fail("Error iterating RNG more than %u times\n", i); + fail("Error iterating RNG-nonce more than %u times\n", i); + exit(1); + } + } + + for (i = 0; i <= 65539; i++) { + ret = gnutls_rnd(GNUTLS_RND_RANDOM, buf1, sizeof(buf1)); + if (ret < 0) { + fail("Error iterating RNG-random more than %u times\n", i); exit(1); } } |