trailing spaces and overlong lines fixes

This commit is contained in:
Reda Chouk 2024-10-01 16:28:31 +02:00
parent 3193ecb2c3
commit 666e658398
3 changed files with 12 additions and 7 deletions

View File

@ -1020,7 +1020,7 @@ static int Hmac_UpdateFinal_CT(Hmac* hmac, byte* digest, const byte* in,
if (ret != 0)
return ret;
ret = Hmac_HashUpdate(hmac, in, (word32)(safeBlocks * blockSz -
WOLFSSL_TLS_HMAC_INNER_SZ));
WOLFSSL_TLS_HMAC_INNER_SZ));
if (ret != 0)
return ret;
}
@ -1278,7 +1278,8 @@ int TLS_hmac(WOLFSSL* ssl, byte* digest, const byte* in, word32 sz, int padSz,
#endif
{
ret = Hmac_UpdateFinal_CT(&hmac, digest, in,
(sz + hashSz + (word32)padSz + 1), (int)hashSz, myInner);
(sz + hashSz + (word32)padSz + 1),
(int)hashSz, myInner);
}
#else
ret = Hmac_UpdateFinal(&hmac, digest, in, sz + hashSz + padSz + 1,

View File

@ -7604,7 +7604,8 @@ static int SendTls13EncryptedExtensions(WOLFSSL* ssl)
/* This handshake message is always encrypted. */
sendSz = BuildTls13Message(ssl, output, sendSz, output + RECORD_HEADER_SZ,
(int)(idx - RECORD_HEADER_SZ), handshake, 1, 0, 0);
(int)(idx - RECORD_HEADER_SZ),
handshake, 1, 0, 0);
if (sendSz < 0)
return sendSz;
@ -8701,7 +8702,8 @@ static int SendTls13Certificate(WOLFSSL* ssl)
{
/* This message is always encrypted. */
sendSz = BuildTls13Message(ssl, output, sendSz,
output + RECORD_HEADER_SZ, (int)(i - RECORD_HEADER_SZ), handshake, 1,
output + RECORD_HEADER_SZ, (int)(i - RECORD_HEADER_SZ),
handshake, 1,
0, 0);
if (sendSz < 0)
return sendSz;
@ -9152,7 +9154,8 @@ static int SendTls13CertificateVerify(WOLFSSL* ssl)
#endif /* !NO_RSA */
#ifdef HAVE_ECC
if (ssl->hsType == DYNAMIC_TYPE_ECC) {
args->sigLen = (word32)args->sendSz - args->idx - HASH_SIG_SIZE -
args->sigLen = (word32)args->sendSz - args->idx -
HASH_SIG_SIZE -
VERIFY_HEADER;
#if defined(WOLFSSL_SM2) && defined(WOLFSSL_SM3)
if (ssl->buffers.keyType != sm2_sa_algo)
@ -10868,7 +10871,8 @@ static int SendTls13Finished(WOLFSSL* ssl)
input = output + Dtls13GetRlHeaderLength(ssl, 1);
#endif /* WOLFSSL_DTLS13 */
AddTls13HandShakeHeader(input, (word32)finishedSz, 0, (word32)finishedSz, finished, ssl);
AddTls13HandShakeHeader(input, (word32)finishedSz, 0, (word32)finishedSz,
finished, ssl);
#if defined(WOLFSSL_RENESAS_TSIP_TLS)
if (ssl->options.side == WOLFSSL_CLIENT_END) {

View File

@ -73124,7 +73124,7 @@ static int test_wolfSSL_TXT_DB(void)
BIO_free(bio);
/* Test index */
ExpectIntEQ(TXT_DB_create_index(db, 3, NULL,
ExpectIntEQ(TXT_DB_create_index(db, 3, NULL,
(wolf_sk_hash_cb)(long unsigned int)TXT_DB_hash,
(wolf_lh_compare_cb)TXT_DB_cmp), 1);
ExpectNotNull(TXT_DB_get_by_index(db, 3, (WOLFSSL_STRING*)fields));