From df914aa64f9f9b6c5a472a438f5d6f7991d26068 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Mon, 6 Dec 2021 11:39:54 +0000 Subject: [Minor] Polish alignment macros --- src/libcryptobox/cryptobox.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/libcryptobox') diff --git a/src/libcryptobox/cryptobox.c b/src/libcryptobox/cryptobox.c index fe4d3df29..41f13ed73 100644 --- a/src/libcryptobox/cryptobox.c +++ b/src/libcryptobox/cryptobox.c @@ -588,7 +588,7 @@ static gsize rspamd_cryptobox_auth_ctx_len (enum rspamd_cryptobox_mode mode) { if (G_LIKELY (mode == RSPAMD_CRYPTOBOX_MODE_25519)) { - return sizeof (crypto_onetimeauth_state) + _Alignof (crypto_onetimeauth_state); + return sizeof (crypto_onetimeauth_state) + RSPAMD_ALIGNOF(crypto_onetimeauth_state); } else { #ifndef HAVE_USABLE_OPENSSL @@ -1440,7 +1440,7 @@ void rspamd_cryptobox_hash_init (rspamd_cryptobox_hash_state_t *p, const guchar *key, gsize keylen) { crypto_generichash_blake2b_state *st = cryptobox_align_ptr (p, - _Alignof(crypto_generichash_blake2b_state)); + RSPAMD_ALIGNOF(crypto_generichash_blake2b_state)); crypto_generichash_blake2b_init (st, key, keylen, crypto_generichash_blake2b_BYTES_MAX); } @@ -1452,7 +1452,7 @@ void rspamd_cryptobox_hash_update (rspamd_cryptobox_hash_state_t *p, const guchar *data, gsize len) { crypto_generichash_blake2b_state *st = cryptobox_align_ptr (p, - _Alignof(crypto_generichash_blake2b_state)); + RSPAMD_ALIGNOF(crypto_generichash_blake2b_state)); crypto_generichash_blake2b_update (st, data, len); } -- cgit v1.2.3