MCPcopy Create free account
hub / github.com/FastLED/FastLED / Malloc

Function Malloc

src/fl/stl/allocator.cpp.hpp:152–165  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

150}
151
152void* Malloc(fl::size size) {
153 void* ptr = Alloc(size);
154
155#if defined(FASTLED_TESTING)
156 if (gMallocFreeHook && ptr) {
157 MemoryGuard allows_hook;
158 if (allows_hook.enabled()) {
159 gMallocFreeHook->onMalloc(ptr, size);
160 }
161 }
162#endif
163
164 return ptr;
165}
166
167void Free(void *ptr) {
168#if defined(FASTLED_TESTING)

Callers 9

allocateMethod · 0.85
allocateFunction · 0.85
createSlabMethod · 0.85
allocateMethod · 0.85
do_allocateMethod · 0.85
allocateMethod · 0.85
FL_TEST_FILEFunction · 0.85
allocateMethod · 0.85
do_allocateMethod · 0.85

Calls 2

enabledMethod · 0.80
onMallocMethod · 0.45

Tested by

no test coverage detected