free allocated memory upon call `join`

When `join` detects a thread has completed, it will free the allocated
memory of the thread. For this we must first copy the allocator. This is
required as the allocated memory holds a reference to the original
allocator. If we free the memory, we would end up with UB as the
allocator would free itself.
622b7c4746Luuk de Gram committed on 6/26/2023, 6:00:57 PMparent8346090
1 file changedLine totals unavailable