t
Fork of mbed-dev by
Diff: platform/mbed_alloc_wrappers.cpp
- Revision:
- 167:e84263d55307
- Parent:
- 160:d5399cc887bb
- Child:
- 174:b96e65c34a4d
--- a/platform/mbed_alloc_wrappers.cpp Thu Jun 08 15:02:37 2017 +0100 +++ b/platform/mbed_alloc_wrappers.cpp Wed Jun 21 17:46:44 2017 +0100 @@ -80,6 +80,7 @@ extern "C" { void * __real__malloc_r(struct _reent * r, size_t size); + void * __real__memalign_r(struct _reent * r, size_t alignment, size_t bytes); void * __real__realloc_r(struct _reent * r, void * ptr, size_t size); void __real__free_r(struct _reent * r, void * ptr); void* __real__calloc_r(struct _reent * r, size_t nmemb, size_t size); @@ -178,8 +179,6 @@ #endif // #ifdef MBED_MEM_TRACING_ENABLED } -#endif // if !defined(FEATURE_UVISOR) - extern "C" void * __wrap__calloc_r(struct _reent * r, size_t nmemb, size_t size) { void *ptr = NULL; #ifdef MBED_HEAP_STATS_ENABLED @@ -200,6 +199,12 @@ return ptr; } +extern "C" void * __wrap__memalign_r(struct _reent * r, size_t alignment, size_t bytes) { + return __real__memalign_r(r, alignment, bytes); +} + +#endif // if !defined(FEATURE_UVISOR) + /******************************************************************************/ /* ARMCC memory allocation wrappers */