CLEANUP: ssl: Remove useless local variable in tlskeys_list_get_next()
authorTim Duesterhus <tim@bastelstu.be>
Sun, 3 Jan 2021 00:29:56 +0000 (01:29 +0100)
committerWilliam Lallemand <wlallemand@haproxy.org>
Thu, 9 Dec 2021 13:01:21 +0000 (14:01 +0100)
`getnext` was only used to fill `ref` at the beginning of the function. Both
have the same type. Replace the parameter name by `ref` to remove the useless
local variable.

(cherry picked from commit cb8b281c022912820898ae9ebaea868cf1a07d58)
Signed-off-by: William Lallemand <wlallemand@haproxy.org>

src/ssl_sock.c

index 07b2123..2a215ed 100644 (file)
@@ -6406,10 +6406,8 @@ static int ssl_sock_show_fd(struct buffer *buf, const struct connection *conn, c
  */
 #if (defined SSL_CTRL_SET_TLSEXT_TICKET_KEY_CB && TLS_TICKETS_NO > 0)
 static inline
-struct tls_keys_ref *tlskeys_list_get_next(struct tls_keys_ref *getnext, struct list *end)
+struct tls_keys_ref *tlskeys_list_get_next(struct tls_keys_ref *ref, struct list *end)
 {
-       struct tls_keys_ref *ref = getnext;
-
        /* Get next list entry. */
        ref = LIST_NEXT(&ref->list, struct tls_keys_ref *, list);