From d57cde5448cea4d61a171791c74d51b32baa521e Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Thu, 21 Mar 2019 02:04:09 +0100 Subject: [PATCH] Remove useless tests, add more meaningful ones. --- test/default/stream.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/test/default/stream.c b/test/default/stream.c index 96c566c8..a216c04c 100644 --- a/test/default/stream.c +++ b/test/default/stream.c @@ -64,19 +64,14 @@ main(void) assert(memcmp(output + 192, output + 64, 64) != 0); assert(memcmp(output + 192, output + 128, 64) != 0); - memset(output + 192, 1, 64); - crypto_stream_xsalsa20_xor_ic(output, output, 64, nonce, - 0ULL, firstkey); - assert(memcmp(output + 192, output, 64) != 0); - assert(memcmp(output + 192, output + 64, 64) != 0); - assert(memcmp(output + 192, output + 128, 64) != 0); - memset(output, 0, 64); crypto_stream_xsalsa20_xor_ic(output, output, 128, nonce, 1ULL << 32, firstkey); assert(memcmp(output, output + 192, 64) != 0); assert(memcmp(output, output + 128, 64) != 0); assert(memcmp(output, output + 64, 64) != 0); + assert(memcmp(output + 64, output + 192, 64) != 0); + assert(memcmp(output + 128, output + 192, 64) != 0); assert(crypto_stream_keybytes() > 0U); assert(crypto_stream_noncebytes() > 0U);