Clean up tls1_change_cipher_state().
authorjsing <jsing@openbsd.org>
Sun, 2 May 2021 17:46:58 +0000 (17:46 +0000)
committerjsing <jsing@openbsd.org>
Sun, 2 May 2021 17:46:58 +0000 (17:46 +0000)
commitb3d9ef4ba1230cbff2d2f2ab596ccd010323e8ed
treecca9b32c305bf8a179d58632f420d4149d4ada4c
parent56985c136a01f2cc7e3fcd2f897091e9f2d15f42
Clean up tls1_change_cipher_state().

Replace flag gymnastics at call sites with separate read and write,
functions which call the common code. Condition on s->server instead of
using SSL_ST_ACCEPT, for consistency and more readable code.

ok inoguchi@ tb@
lib/libssl/ssl_clnt.c
lib/libssl/ssl_locl.h
lib/libssl/ssl_pkt.c
lib/libssl/ssl_srvr.c
lib/libssl/t1_enc.c