X-Git-Url: https://git.distorted.org.uk/~mdw/disorder/blobdiff_plain/a1bedb6db8934e6788075a1e1cda001356cf1d8b..3ece470d21e4fcc14337db1d631290d5e7cd4959:/lib/t-mime.c diff --git a/lib/t-mime.c b/lib/t-mime.c index eb5ee7c..5c3152a 100644 --- a/lib/t-mime.c +++ b/lib/t-mime.c @@ -220,7 +220,9 @@ void test_mime(void) { "Now's the time for all folk to come to the aid of their country."); #define check_base64(encoded, decoded) do { \ - check_string(mime_base64(encoded, 0), decoded); \ + size_t ns; \ + check_string(mime_base64(encoded, &ns), decoded); \ + insist(ns == (sizeof decoded) - 1); \ check_string(mime_to_base64((const uint8_t *)decoded, \ (sizeof decoded) - 1), \ encoded); \