From eb3e849e63e32cc015aa21c4481b232bf69c8976 Mon Sep 17 00:00:00 2001 From: Antonio Quartulli Date: Mon, 10 Jan 2022 15:45:10 +0100 Subject: [PATCH] ssl.c: use arrow operator to access object member The arrow operator exists exactly to perform a pointer dereference implicitly while accessing a member. while at it, add whitespaces around the '-' operator on the same line. Signed-off-by: Antonio Quartulli Acked-by: Gert Doering Message-Id: <20220110144510.17769-1-a@unstable.cc> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg23521.html Signed-off-by: Gert Doering --- src/openvpn/ssl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/openvpn/ssl.c b/src/openvpn/ssl.c index 96c78199a..db0e72818 100644 --- a/src/openvpn/ssl.c +++ b/src/openvpn/ssl.c @@ -1669,9 +1669,9 @@ init_key_contexts(struct key_ctx_bi *key, init_key_ctx_bi(key, key2, key_direction, key_type, "Data Channel"); /* Initialize implicit IVs */ - key_ctx_update_implicit_iv(&key->encrypt, (*key2).keys[(int)server].hmac, + key_ctx_update_implicit_iv(&key->encrypt, key2->keys[(int)server].hmac, MAX_HMAC_KEY_LENGTH); - key_ctx_update_implicit_iv(&key->decrypt, (*key2).keys[1-(int)server].hmac, + key_ctx_update_implicit_iv(&key->decrypt, key2->keys[1 - (int)server].hmac, MAX_HMAC_KEY_LENGTH); } -- 2.47.2