clean up variable definitions

This commit is contained in:
John Bland
2024-01-03 17:39:20 -05:00
parent e1435e96d2
commit 245c87fe8f

View File

@ -21162,10 +21162,11 @@ default:
ssl->keys.decryptedCur = 1;
#ifdef WOLFSSL_TLS13
if (ssl->options.tls1_3) {
/* check that the end of the logical length doesn't extend
* past the real buffer */
word16 i;
word32 boundsCheck = (ssl->buffers.inputBuffer.idx +
ssl->curSize - ssl->specs.aead_mac_size);
/* check that the end of the logical length doesn't extend
* past the real buffer */
if (boundsCheck > ssl->buffers.inputBuffer.length ||
boundsCheck == 0) {
WOLFSSL_ERROR(BUFFER_ERROR);
@ -21173,7 +21174,7 @@ default:
}
/* end of plaintext */
word16 i = (word16)(boundsCheck);
i = (word16)(boundsCheck);
/* Remove padding from end of plain text. */
for (--i; i > ssl->buffers.inputBuffer.idx; i--) {