From bcb15b6a03bc19d4fe146ce1d46e5554233232e9 Mon Sep 17 00:00:00 2001 From: tb <> Date: Thu, 7 Jan 2021 16:26:31 +0000 Subject: Rename two local variables ssl to s for consistency In our tls13_* files, we use SSL *s for local variables and SSL *ssl for function arguments. This is odd, but probably the result of finger memory. We intended to use ssl everywhere. Be that as it may, all local variables except in two functions ended up being called s, so align the two outliers with that. As noted by jsing, this is not ideal either as in tls13_legacy_servername_process() the ssl_ctx is now inconsistent. Renaming all s to ssl is a substantial amount of unnecessary churn at a moment that isn't ideal, so we have to live with that. ok bcook inoguchi jsing --- src/lib/libssl/tls13_legacy.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/lib/libssl/tls13_legacy.c') diff --git a/src/lib/libssl/tls13_legacy.c b/src/lib/libssl/tls13_legacy.c index 8aa806aa45..bacd11b950 100644 --- a/src/lib/libssl/tls13_legacy.c +++ b/src/lib/libssl/tls13_legacy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_legacy.c,v 1.20 2021/01/04 19:19:12 tb Exp $ */ +/* $OpenBSD: tls13_legacy.c,v 1.21 2021/01/07 16:26:31 tb Exp $ */ /* * Copyright (c) 2018, 2019 Joel Sing * @@ -515,14 +515,14 @@ tls13_legacy_servername_process(struct tls13_ctx *ctx, uint8_t *alert) int legacy_alert = SSL_AD_UNRECOGNIZED_NAME; int ret = SSL_TLSEXT_ERR_NOACK; SSL_CTX *ssl_ctx = ctx->ssl->ctx; - SSL *ssl = ctx->ssl; + SSL *s = ctx->ssl; if (ssl_ctx->internal->tlsext_servername_callback == NULL) - ssl_ctx = ssl->initial_ctx; + ssl_ctx = s->initial_ctx; if (ssl_ctx->internal->tlsext_servername_callback == NULL) return 1; - ret = ssl_ctx->internal->tlsext_servername_callback(ssl, &legacy_alert, + ret = ssl_ctx->internal->tlsext_servername_callback(s, &legacy_alert, ssl_ctx->internal->tlsext_servername_arg); if (ret == SSL_TLSEXT_ERR_ALERT_FATAL || -- cgit v1.2.3-55-g6feb