mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-31 11:17:29 +02:00
dtls: malloc needs to allocate the size of the dereferenced object
This commit is contained in:
@ -1220,7 +1220,7 @@ int TLSX_ConnectionID_Use(WOLFSSL* ssl)
|
|||||||
info = (CIDInfo*)XMALLOC(sizeof(CIDInfo), ssl->heap, DYNAMIC_TYPE_TLSX);
|
info = (CIDInfo*)XMALLOC(sizeof(CIDInfo), ssl->heap, DYNAMIC_TYPE_TLSX);
|
||||||
if (info == NULL)
|
if (info == NULL)
|
||||||
return MEMORY_ERROR;
|
return MEMORY_ERROR;
|
||||||
ext = (WOLFSSL**)XMALLOC(sizeof(WOLFSSL**), ssl->heap, DYNAMIC_TYPE_TLSX);
|
ext = (WOLFSSL**)XMALLOC(sizeof(WOLFSSL*), ssl->heap, DYNAMIC_TYPE_TLSX);
|
||||||
if (ext == NULL) {
|
if (ext == NULL) {
|
||||||
XFREE(info, ssl->heap, DYNAMIC_TYPE_TLSX);
|
XFREE(info, ssl->heap, DYNAMIC_TYPE_TLSX);
|
||||||
return MEMORY_ERROR;
|
return MEMORY_ERROR;
|
||||||
|
Reference in New Issue
Block a user