mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 02:03:12 +02:00
nullptr safety
This commit is contained in:
parent
6423571349
commit
b582f178dd
@ -116,11 +116,14 @@ public:
|
||||
if( static_cast<size_t>( itemIndex ) < jobs.size() )
|
||||
{
|
||||
JOBSET_JOB& job = jobs[itemIndex];
|
||||
|
||||
if( m_output->m_lastRunReporters.contains( job.m_id ) )
|
||||
{
|
||||
WX_STRING_REPORTER* reporter =
|
||||
static_cast<WX_STRING_REPORTER*>( m_output->m_lastRunReporters[job.m_id] );
|
||||
m_textCtrlOutput->SetValue( reporter->GetMessages() );
|
||||
|
||||
if( reporter )
|
||||
m_textCtrlOutput->SetValue( reporter->GetMessages() );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -178,8 +178,8 @@ bool JOBS_RUNNER::RunJobsForOutput( JOBSET_OUTPUT* aOutput, bool aBail )
|
||||
|
||||
aOutput->m_lastRunSuccessMap.clear();
|
||||
|
||||
for( auto& reporter : aOutput->m_lastRunReporters )
|
||||
delete reporter.second;
|
||||
for( auto& [name, reporter] : aOutput->m_lastRunReporters )
|
||||
delete reporter;
|
||||
|
||||
aOutput->m_lastRunReporters.clear();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user