Skip to content

Commit e3c2c65

Browse files
committed
infer: fix dead store, and uninitialized value errors.
1 parent 0f8b4db commit e3c2c65

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/ssl.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20411,7 +20411,6 @@ WOLFSSL_CTX* wolfSSL_set_SSL_CTX(WOLFSSL* ssl, WOLFSSL_CTX* ctx)
2041120411
}
2041220412

2041320413
ssl->buffers.weOwnCert = 1;
20414-
ret = WOLFSSL_SUCCESS;
2041520414
}
2041620415
if (ctx->certChain != NULL) {
2041720416
if (ssl->buffers.certChain != NULL) {
@@ -20425,7 +20424,6 @@ WOLFSSL_CTX* wolfSSL_set_SSL_CTX(WOLFSSL* ssl, WOLFSSL_CTX* ctx)
2042520424
}
2042620425

2042720426
ssl->buffers.weOwnCertChain = 1;
20428-
ret = WOLFSSL_SUCCESS;
2042920427
}
2043020428
#else
2043120429
/* ctx owns certificate, certChain and key */

src/tls13.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8568,6 +8568,8 @@ static int SendTls13Certificate(WOLFSSL* ssl)
85688568
WOLFSSL_START(WC_FUNC_CERTIFICATE_SEND);
85698569
WOLFSSL_ENTER("SendTls13Certificate");
85708570

8571+
XMEMSET(extSz, 0, sizeof(extSz));
8572+
85718573
ssl->options.buildingMsg = 1;
85728574

85738575
#ifdef WOLFSSL_POST_HANDSHAKE_AUTH

tests/api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5031,7 +5031,7 @@ static int test_wolfSSL_CTX_use_certificate_chain_buffer_format(void)
50315031
WOLFSSL* ssl = NULL;
50325032
const char* cert = "./certs/server-cert.pem";
50335033
unsigned char* buf = NULL;
5034-
size_t len;
5034+
size_t len = 0;
50355035

50365036
ExpectIntEQ(load_file(cert, &buf, &len), 0);
50375037

0 commit comments

Comments
 (0)