mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-26 16:04:34 +00:00
Symbol might be unavailable.
This commit is contained in:
parent
6721db8600
commit
8740ea710a
@ -193,10 +193,18 @@ void View::DrawFlameGraphItem( const FlameGraphItem& item, FlameGraphContext& ct
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
auto sym = m_worker.GetSymbolData( (uint64_t)item.srcloc );
|
auto sym = m_worker.GetSymbolData( (uint64_t)item.srcloc );
|
||||||
name = m_worker.GetString( sym->name );
|
if( sym )
|
||||||
auto namehash = charutil::hash( name );
|
{
|
||||||
if( namehash == 0 ) namehash++;
|
name = m_worker.GetString( sym->name );
|
||||||
color = GetHsvColor( namehash, depth );
|
auto namehash = charutil::hash( name );
|
||||||
|
if( namehash == 0 ) namehash++;
|
||||||
|
color = GetHsvColor( namehash, depth );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
name = "???";
|
||||||
|
color = 0xFF888888;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto hiColor = HighlightColor( color );
|
const auto hiColor = HighlightColor( color );
|
||||||
|
Loading…
Reference in New Issue
Block a user