提交 bbea9f2c 编写于 作者: T Tatsuhiro Tsujikawa 提交者: Matt Caswell

Restore s->early_data_state with the original value

Reviewed-by: NRich Salz <rsalz@openssl.org>
Reviewed-by: NMatt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3091)
上级 f8a303fa
......@@ -1830,12 +1830,14 @@ int SSL_write_early_data(SSL *s, const void *buf, size_t num, size_t *written)
return ret;
case SSL_EARLY_DATA_FINISHED_READING:
case SSL_EARLY_DATA_READ_RETRY:
case SSL_EARLY_DATA_READ_RETRY: {
int early_data_state = s->early_data_state;
/* We are a server writing to an unauthenticated client */
s->early_data_state = SSL_EARLY_DATA_UNAUTH_WRITING;
ret = SSL_write_ex(s, buf, num, written);
s->early_data_state = SSL_EARLY_DATA_READ_RETRY;
s->early_data_state = early_data_state;
return ret;
}
default:
SSLerr(SSL_F_SSL_WRITE_EARLY_DATA, ERR_R_SHOULD_NOT_HAVE_BEEN_CALLED);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册