]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-dcrypt: test-crypto - Add missing test_asserts to test_x25519_keypair
authorAki Tuomi <aki.tuomi@open-xchange.com>
Wed, 14 Feb 2024 07:31:39 +0000 (09:31 +0200)
committertimo.sirainen <timo.sirainen@open-xchange.com>
Wed, 14 Feb 2024 17:26:29 +0000 (17:26 +0000)
src/lib-dcrypt/test-crypto.c

index 93038055dab19f9cd3a2432680ea9768aad7e490..51aa984146e2640f23c9c7466997a26bce191e78 100644 (file)
@@ -1928,8 +1928,10 @@ static void test_xd25519_keypair(void)
        string_t *pub = t_str_new(64);
        string_t *priv = t_str_new(64);
 
-       dcrypt_key_store_public(pair.pub, DCRYPT_FORMAT_DOVECOT, pub, &error);
-       dcrypt_key_store_private(pair.priv, DCRYPT_FORMAT_DOVECOT, NULL, priv, NULL, NULL, &error);
+       ret = dcrypt_key_store_public(pair.pub, DCRYPT_FORMAT_DOVECOT, pub, &error);
+       test_assert(ret == TRUE);
+       ret = dcrypt_key_store_private(pair.priv, DCRYPT_FORMAT_DOVECOT, NULL, priv, NULL, NULL, &error);
+       test_assert(ret == TRUE);
 
        struct dcrypt_keypair pair2;