Fix scenario where FreeHandshakeResources is called and server hello is recevied and WOLFSSL arrays is NULL.

This commit is contained in:
David Garske
2020-11-12 09:21:39 -08:00
parent c7bb602a30
commit c7053e9a36

View File

@ -2648,7 +2648,7 @@ static int ProcessServerHello(int msgSz, const byte* input, int* sslBytes,
(void)initialBytes;
/* make sure we didn't miss ClientHello */
if (session->flags.clientHello == 0) {
if (session->flags.clientHello == 0 || session->sslClient->arrays == NULL) {
SetError(MISSED_CLIENT_HELLO_STR, error, session, FATAL_ERROR_STATE);
return -1;
}