FastLED 3.10.6
Loading...
Searching...
No Matches

◆ cleanup()

template<typename T, fl::size SLAB_SIZE = FASTLED_DEFAULT_SLAB_SIZE>
void fl::SlabAllocator< T, SLAB_SIZE >::cleanup ( )
inline

Definition at line 694 of file allocator.h.

694 {
695 fl::detail::slab_lock_guard guard(mMutex); // see allocate()
696 while (mSlabs) {
697 Slab* next = mSlabs->next;
698 mSlabs->~Slab();
699 Free(mSlabs);
700 mSlabs = next;
701 }
702 mTotalAllocated = 0;
704 }
fl::size mTotalDeallocated
Definition allocator.h:489
fl::size mTotalAllocated
Definition allocator.h:488
fl::detail::slab_mutex mMutex
Definition allocator.h:487
void Free(void *ptr)

References fl::FL_NO_EXCEPT, fl::Free(), mMutex, mSlabs, mTotalAllocated, and mTotalDeallocated.

Referenced by ~SlabAllocator(), and operator=().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: