Skip to content

Commit 4e5a98e

Browse files
committed
Fix from rebase
1 parent fd4db14 commit 4e5a98e

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

wolfcrypt/src/memory.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1141,6 +1141,10 @@ void wolfSSL_Free(void *ptr, void* heap, int type)
11411141
#endif
11421142
}
11431143
mem = hint->memory;
1144+
if (mem == NULL) {
1145+
WOLFSSL_MSG("Bad hint pointer to memory");
1146+
return;
1147+
}
11441148

11451149
/* get memory struct and add it to available list */
11461150
pt = (wc_Memory*)((byte*)ptr - sizeof(wc_Memory) - padSz);

0 commit comments

Comments
 (0)