mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-30 01:04:36 +00:00
Don't memcpy to nullptr.
This commit is contained in:
parent
c8ff8540f9
commit
ba9b35dc3b
@ -27,6 +27,8 @@ void ThreadCompress::Load( FileRead& f, int fileVer )
|
|||||||
if( fileVer >= FileVersion( 0, 4, 4 ) )
|
if( fileVer >= FileVersion( 0, 4, 4 ) )
|
||||||
{
|
{
|
||||||
f.Read( sz );
|
f.Read( sz );
|
||||||
|
if( sz != 0 )
|
||||||
|
{
|
||||||
m_threadExpand.reserve_and_use( sz );
|
m_threadExpand.reserve_and_use( sz );
|
||||||
f.Read( m_threadExpand.data(), sizeof( uint64_t ) * sz );
|
f.Read( m_threadExpand.data(), sizeof( uint64_t ) * sz );
|
||||||
m_threadMap.reserve( sz );
|
m_threadMap.reserve( sz );
|
||||||
@ -35,6 +37,7 @@ void ThreadCompress::Load( FileRead& f, int fileVer )
|
|||||||
m_threadMap.emplace( m_threadExpand[i], i );
|
m_threadMap.emplace( m_threadExpand[i], i );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
f.Read( sz );
|
f.Read( sz );
|
||||||
|
Loading…
Reference in New Issue
Block a user