diff options
author | tb <> | 2021-01-07 16:26:31 +0000 |
---|---|---|
committer | tb <> | 2021-01-07 16:26:31 +0000 |
commit | bcb15b6a03bc19d4fe146ce1d46e5554233232e9 (patch) | |
tree | 5da288aa44b33848ba53cc82cd8153fcd0ad64e8 /src/lib/libssl/tls13_legacy.c | |
parent | f020ab198f74d42865692869fdee46cb49c7d1c5 (diff) | |
download | openbsd-bcb15b6a03bc19d4fe146ce1d46e5554233232e9.tar.gz openbsd-bcb15b6a03bc19d4fe146ce1d46e5554233232e9.tar.bz2 openbsd-bcb15b6a03bc19d4fe146ce1d46e5554233232e9.zip |
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
Diffstat (limited to '')
-rw-r--r-- | src/lib/libssl/tls13_legacy.c | 8 |
1 files changed, 4 insertions, 4 deletions
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 @@ | |||
1 | /* $OpenBSD: tls13_legacy.c,v 1.20 2021/01/04 19:19:12 tb Exp $ */ | 1 | /* $OpenBSD: tls13_legacy.c,v 1.21 2021/01/07 16:26:31 tb Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2018, 2019 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2018, 2019 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -515,14 +515,14 @@ tls13_legacy_servername_process(struct tls13_ctx *ctx, uint8_t *alert) | |||
515 | int legacy_alert = SSL_AD_UNRECOGNIZED_NAME; | 515 | int legacy_alert = SSL_AD_UNRECOGNIZED_NAME; |
516 | int ret = SSL_TLSEXT_ERR_NOACK; | 516 | int ret = SSL_TLSEXT_ERR_NOACK; |
517 | SSL_CTX *ssl_ctx = ctx->ssl->ctx; | 517 | SSL_CTX *ssl_ctx = ctx->ssl->ctx; |
518 | SSL *ssl = ctx->ssl; | 518 | SSL *s = ctx->ssl; |
519 | 519 | ||
520 | if (ssl_ctx->internal->tlsext_servername_callback == NULL) | 520 | if (ssl_ctx->internal->tlsext_servername_callback == NULL) |
521 | ssl_ctx = ssl->initial_ctx; | 521 | ssl_ctx = s->initial_ctx; |
522 | if (ssl_ctx->internal->tlsext_servername_callback == NULL) | 522 | if (ssl_ctx->internal->tlsext_servername_callback == NULL) |
523 | return 1; | 523 | return 1; |
524 | 524 | ||
525 | ret = ssl_ctx->internal->tlsext_servername_callback(ssl, &legacy_alert, | 525 | ret = ssl_ctx->internal->tlsext_servername_callback(s, &legacy_alert, |
526 | ssl_ctx->internal->tlsext_servername_arg); | 526 | ssl_ctx->internal->tlsext_servername_arg); |
527 | 527 | ||
528 | if (ret == SSL_TLSEXT_ERR_ALERT_FATAL || | 528 | if (ret == SSL_TLSEXT_ERR_ALERT_FATAL || |