aboutsummaryrefslogtreecommitdiff
path: root/tests/test-crypto-cipher.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test-crypto-cipher.c')
-rw-r--r--tests/test-crypto-cipher.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/tests/test-crypto-cipher.c b/tests/test-crypto-cipher.c
index 07fa2fa..bebba1a4 100644
--- a/tests/test-crypto-cipher.c
+++ b/tests/test-crypto-cipher.c
@@ -761,10 +761,7 @@ static void test_cipher_short_plaintext(void)
sizeof(plaintext1),
&err);
g_assert(ret == -1);
- g_assert(err != NULL);
-
- error_free(err);
- err = NULL;
+ error_free_or_abort(&err);
/* Should report an error as plaintext is larger than
* block size, but not a multiple of block size
@@ -775,9 +772,8 @@ static void test_cipher_short_plaintext(void)
sizeof(plaintext2),
&err);
g_assert(ret == -1);
- g_assert(err != NULL);
+ error_free_or_abort(&err);
- error_free(err);
qcrypto_cipher_free(cipher);
}