PCM: fix crash in background update on project switch

Fixes #12244
This commit is contained in:
qu1ck 2022-08-19 15:09:05 -07:00
parent 1fa1b44d02
commit e19e039a47
1 changed files with 4 additions and 0 deletions

View File

@ -1048,6 +1048,10 @@ std::unordered_map<wxString, wxBitmap> PLUGIN_CONTENT_MANAGER::GetInstalledPacka
void PLUGIN_CONTENT_MANAGER::RunBackgroundUpdate()
{
// If the thread is already running don't create it again
if( m_updateThread.joinable() )
return;
m_statusReporter = std::make_shared<STATUS_TEXT_REPORTER>( m_statusCallback );
m_updateThread = std::thread(