forked from wolfSSL/wolfssl
Merge pull request #4249 from dgarske/ecc_heap
Fix for `wc_ecc_ctx_free` and heap hint
This commit is contained in:
@ -11176,8 +11176,10 @@ ecEncCtx* wc_ecc_ctx_new(int flags, WC_RNG* rng)
|
||||
void wc_ecc_ctx_free(ecEncCtx* ctx)
|
||||
{
|
||||
if (ctx) {
|
||||
void* heap = ctx->heap;
|
||||
ForceZero(ctx, sizeof(ecEncCtx));
|
||||
XFREE(ctx, ctx->heap, DYNAMIC_TYPE_ECC);
|
||||
XFREE(ctx, heap, DYNAMIC_TYPE_ECC);
|
||||
(void)heap;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user