mirror of
https://github.com/wolfpld/tracy.git
synced 2026-10-29 12:05:30 +00:00
Report failed second-trace loads in compare instead of crashing.
The compare load thread caught only UnsupportedVersion, so a corrupted or otherwise unloadable second trace escaped the thread as std::terminate. Catch the same set as the main trace load and route it to the existing bad-version dialog.
This commit is contained in:
@@ -245,6 +245,20 @@ void View::DrawCompare()
|
||||
m_compare.badVer.state = BadVersionState::UnsupportedVersion;
|
||||
m_compare.badVer.version = e.version;
|
||||
}
|
||||
catch( const tracy::LegacyVersion& e )
|
||||
{
|
||||
m_compare.badVer.state = BadVersionState::LegacyVersion;
|
||||
m_compare.badVer.version = e.version;
|
||||
}
|
||||
catch( const tracy::LoadFailure& e )
|
||||
{
|
||||
m_compare.badVer.state = BadVersionState::LoadFailure;
|
||||
m_compare.badVer.msg = e.msg;
|
||||
}
|
||||
catch( const tracy::FileReadError& )
|
||||
{
|
||||
m_compare.badVer.state = BadVersionState::ReadError;
|
||||
}
|
||||
} );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user