Skip to content

Commit 81f0ce2

Browse files
committed
Reset init state in SSL_process_quic_post_handshake()
1 parent 5d59cf9 commit 81f0ce2

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

ssl/ssl_quic.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,16 +268,19 @@ int quic_set_encryption_secrets(SSL *ssl, OSSL_ENCRYPTION_LEVEL level)
268268

269269
int SSL_process_quic_post_handshake(SSL *ssl)
270270
{
271+
int ret;
272+
271273
if (SSL_in_init(ssl) || !SSL_IS_QUIC(ssl)) {
272274
SSLerr(SSL_F_SSL_PROCESS_QUIC_POST_HANDSHAKE, ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED);
273275
return 0;
274276
}
275277

276278
ossl_statem_set_in_init(ssl, 1);
279+
ret = ssl->handshake_func(ssl);
280+
ossl_statem_set_in_init(ssl, 0);
277281

278-
if (ssl->handshake_func(ssl) <= 0)
282+
if (ret <= 0)
279283
return 0;
280-
281284
return 1;
282285
}
283286

0 commit comments

Comments
 (0)