mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-23 06:44:35 +00:00
Change ev.ptr nullptr early-out to happen only when there is not a previous allocation for address 0. Custom memory pools (like custom allocators for Vulkan memory pools) can allocate at address 0, so the previous code would cause the Tracy server to alloc(0), free(0) (but early out), then on the next alloc(0) it would have a MemAllocTwiceFailure (because it skipped the free).
This commit is contained in:
parent
da9a32fd09
commit
be963f184c
@ -5602,11 +5602,11 @@ MemEvent* Worker::ProcessMemFreeImpl( uint64_t memname, MemData& memdata, const
|
||||
const auto refTime = m_refTimeSerial + ev.time;
|
||||
m_refTimeSerial = refTime;
|
||||
|
||||
if( ev.ptr == 0 ) return nullptr;
|
||||
|
||||
auto it = memdata.active.find( ev.ptr );
|
||||
if( it == memdata.active.end() )
|
||||
{
|
||||
if( ev.ptr == 0 ) return nullptr;
|
||||
|
||||
if( !m_ignoreMemFreeFaults )
|
||||
{
|
||||
CheckThreadString( ev.thread );
|
||||
|
Loading…
Reference in New Issue
Block a user