mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-05 05:30:50 +02:00
+2
-1
@@ -663,8 +663,9 @@ int wolfSSL_CTX_SetTmpEC_DHE_Sz(WOLFSSL_CTX* ctx, word16 sz)
|
||||
if (sz < ECC_MINSIZE) {
|
||||
ret = BAD_FUNC_ARG;
|
||||
}
|
||||
else
|
||||
#endif
|
||||
else if (sz > ECC_MAXSIZE) {
|
||||
if (sz > ECC_MAXSIZE) {
|
||||
ret = BAD_FUNC_ARG;
|
||||
}
|
||||
else {
|
||||
|
||||
+4
-2
@@ -1206,12 +1206,14 @@ PKCS7* wolfSSL_SMIME_read_PKCS7(WOLFSSL_BIO* in,
|
||||
/* If line endings were added, the initial length may be
|
||||
* exceeded. */
|
||||
if ((canonPos + canonLineLen) >= canonSize) {
|
||||
char* newCanonSection;
|
||||
canonSize = canonPos + canonLineLen;
|
||||
canonSection = (char*)XREALLOC(canonSection, canonSize,
|
||||
newCanonSection = (char*)XREALLOC(canonSection, canonSize,
|
||||
NULL, DYNAMIC_TYPE_PKCS7);
|
||||
if (canonSection == NULL) {
|
||||
if (newCanonSection == NULL) {
|
||||
goto error;
|
||||
}
|
||||
canonSection = newCanonSection;
|
||||
}
|
||||
XMEMCPY(&canonSection[canonPos], canonLine,
|
||||
(int)canonLineLen - 1);
|
||||
|
||||
Reference in New Issue
Block a user