]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
gnutls_cipher_add_auth: propagate error codes
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Sun, 1 Jul 2018 20:08:16 +0000 (22:08 +0200)
committerNikos Mavrogiannopoulos <nmav@redhat.com>
Mon, 2 Jul 2018 12:40:29 +0000 (14:40 +0200)
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
lib/crypto-api.c

index c3d367b542fdb95fa3e3f1b303b3daefd85ae6e8..4dbd633d884869614ad0b2dadcb01bec8936f374 100644 (file)
@@ -138,9 +138,7 @@ gnutls_cipher_add_auth(gnutls_cipher_hd_t handle, const void *ptext,
        if (_gnutls_cipher_is_aead(&h->ctx_enc) == 0)
                return gnutls_assert_val(GNUTLS_E_INVALID_REQUEST);
 
-       _gnutls_cipher_auth(&h->ctx_enc, ptext, ptext_size);
-
-       return 0;
+       return _gnutls_cipher_auth(&h->ctx_enc, ptext, ptext_size);
 }
 
 /**