summaryrefslogtreecommitdiff
path: root/src/test/test_crypto.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2015-11-26 10:00:12 -0500
committerNick Mathewson <nickm@torproject.org>2015-11-26 10:00:12 -0500
commit0285054189d5cbc55bb0d40805e801e13cfb882d (patch)
tree95911da558f5c75681b2a21f27119d3fd5795a84 /src/test/test_crypto.c
parentfe46fffd980cb97661b6bf0f16c66522d7e58e61 (diff)
downloadtor-0285054189d5cbc55bb0d40805e801e13cfb882d.tar.gz
tor-0285054189d5cbc55bb0d40805e801e13cfb882d.zip
Fix buffer size in sha512 unit test
Nobody likes a stack overflow, even in unit tests. Closes 17699; but not in any released tor.
Diffstat (limited to 'src/test/test_crypto.c')
-rw-r--r--src/test/test_crypto.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/test_crypto.c b/src/test/test_crypto.c
index fcce2c52cb..204c066c71 100644
--- a/src/test/test_crypto.c
+++ b/src/test/test_crypto.c
@@ -287,7 +287,7 @@ test_crypto_sha(void *arg)
char key[160];
char digest[32];
char data[50];
- char d_out1[DIGEST_LEN], d_out2[DIGEST256_LEN];
+ char d_out1[DIGEST_LEN], d_out2[DIGEST512_LEN];
char *mem_op_hex_tmp=NULL;
/* Test SHA-1 with a test vector from the specification. */