diff options
author | Nick Mathewson <nickm@torproject.org> | 2009-10-26 21:52:35 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2009-10-26 22:40:41 -0400 |
commit | cec698d29ed51ed219f907e12538e6945e535e4a (patch) | |
tree | 8abf8c47ed046561304183ed99fa6f8a7997b9ab /src/test/test_crypto.c | |
parent | a457cd91fafdce6e7d63ef2089233768498335f2 (diff) | |
download | tor-cec698d29ed51ed219f907e12538e6945e535e4a.tar.gz tor-cec698d29ed51ed219f907e12538e6945e535e4a.zip |
Fix CID 409: check return value of base64_encode in tests
Diffstat (limited to 'src/test/test_crypto.c')
-rw-r--r-- | src/test/test_crypto.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/test/test_crypto.c b/src/test/test_crypto.c index 670fd0048f..656c3c94fc 100644 --- a/src/test/test_crypto.c +++ b/src/test/test_crypto.c @@ -455,6 +455,7 @@ test_crypto_formats(void) strlcat(data1, " 2nd string that contains 35 chars.", 1024); i = base64_encode(data2, 1024, data1, 71); + test_assert(i >= 0); j = base64_decode(data3, 1024, data2, i); test_eq(j, 71); test_streq(data3, data1); |