zephyr/subsys/net/lib/openthread/platform/memory.c
Kamil Kasperczyk 7b26544547 net: openthread: added heap related otPlat methods implementation
* Added implementations of otPlatCAlloc and otPlatFree methods
necessary for the OpenThread in case of using EXTERNAL_HEAP.
* Added CONFIG_OPENTHREAD_DNSSD_SERVER option to allow enabling
OT_DNSS_SERVER feature.

Signed-off-by: Kamil Kasperczyk <kamil.kasperczyk@nordicsemi.no>
2021-02-18 18:23:06 +02:00

22 lines
305 B
C

/*
* Copyright (c) 2021 Nordic Semiconductor ASA
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <kernel.h>
#include <openthread/platform/memory.h>
#include <stdlib.h>
void *otPlatCAlloc(size_t aNum, size_t aSize)
{
return calloc(aNum, aSize);
}
void otPlatFree(void *aPtr)
{
free(aPtr);
}