mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-16 15:21:41 +00:00
VideoBackendBase: Only populate backend info when uninitialized
Prevent potential issues when creating the Graphics window (and thus calling PopulateBackendInfo) while the core state is Stopping, like we already do while it's Starting or Running.
This commit is contained in:
parent
2cb124bd3a
commit
dc1b961c09
1 changed files with 3 additions and 3 deletions
|
@ -284,9 +284,9 @@ void VideoBackendBase::ActivateBackend(const std::string& name)
|
||||||
|
|
||||||
void VideoBackendBase::PopulateBackendInfo(const WindowSystemInfo& wsi)
|
void VideoBackendBase::PopulateBackendInfo(const WindowSystemInfo& wsi)
|
||||||
{
|
{
|
||||||
// If the core is running, the backend info will have been populated already. If we did it here,
|
// If the core has been initialized, the backend info will have been populated already. Doing it
|
||||||
// the UI thread could race with the GPU thread.
|
// again would be unnecessary and could cause the UI thread to race with the GPU thread.
|
||||||
if (Core::IsRunningOrStarting(Core::System::GetInstance()))
|
if (Core::GetState(Core::System::GetInstance()) != Core::State::Uninitialized)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
g_Config.Refresh();
|
g_Config.Refresh();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue