Skip to content

Commit ca5b484

Browse files
authored
Merge pull request #9752 from douzzer/20260207-fixes
20260207-fixes
2 parents fbc5502 + d369539 commit ca5b484

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/ssl_api_pk.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -663,8 +663,9 @@ int wolfSSL_CTX_SetTmpEC_DHE_Sz(WOLFSSL_CTX* ctx, word16 sz)
663663
if (sz < ECC_MINSIZE) {
664664
ret = BAD_FUNC_ARG;
665665
}
666+
else
666667
#endif
667-
else if (sz > ECC_MAXSIZE) {
668+
if (sz > ECC_MAXSIZE) {
668669
ret = BAD_FUNC_ARG;
669670
}
670671
else {

src/ssl_p7p12.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1206,12 +1206,14 @@ PKCS7* wolfSSL_SMIME_read_PKCS7(WOLFSSL_BIO* in,
12061206
/* If line endings were added, the initial length may be
12071207
* exceeded. */
12081208
if ((canonPos + canonLineLen) >= canonSize) {
1209+
char* newCanonSection;
12091210
canonSize = canonPos + canonLineLen;
1210-
canonSection = (char*)XREALLOC(canonSection, canonSize,
1211+
newCanonSection = (char*)XREALLOC(canonSection, canonSize,
12111212
NULL, DYNAMIC_TYPE_PKCS7);
1212-
if (canonSection == NULL) {
1213+
if (newCanonSection == NULL) {
12131214
goto error;
12141215
}
1216+
canonSection = newCanonSection;
12151217
}
12161218
XMEMCPY(&canonSection[canonPos], canonLine,
12171219
(int)canonLineLen - 1);

0 commit comments

Comments
 (0)