From eb7a49a1d765f3b2834697ee533d0a2f5ad898d2 Mon Sep 17 00:00:00 2001 From: Juliusz Sosinowicz Date: Fri, 29 May 2020 21:40:00 +0200 Subject: [PATCH] ASYNC: Working TLS SCR --- src/internal.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/internal.c b/src/internal.c index 9700782c4..78685209e 100644 --- a/src/internal.c +++ b/src/internal.c @@ -15162,10 +15162,6 @@ int ProcessReply(WOLFSSL* ssl) ssl->keys.padSz += 1; ssl->keys.decryptedCur = 1; } - else { - ssl->keys.padSz += 1; - ssl->keys.padSz -= 1; - } } else #endif @@ -23855,7 +23851,10 @@ int SendCertificateVerify(WOLFSSL* ssl) WOLFSSL_ENTER("SendCertificateVerify"); #ifdef WOLFSSL_ASYNC_CRYPT - ret = wolfSSL_AsyncPop(ssl, &ssl->options.asyncState); + /* BuildMessage does its own Pop */ + if (ssl->error != WC_PENDING_E || + ssl->options.asyncState != TLS_ASYNC_END) + ret = wolfSSL_AsyncPop(ssl, &ssl->options.asyncState); if (ret != WC_NOT_PENDING_E) { /* Check for error */ if (ret < 0)