Frontend PR fixes (#6378)
* citra_qt: Check if renderer is null * core: Fix dynarmic use-after-free error * bootmanager: Add current context check in DoneCurrent * Loading a save state would destroy the frame dumper class, which contains a shared context. That context would call DoneCurrent without checking if it was actually bound or not, resulting in crashes when calling opengl functions * externals: Correct glad readme * common: Log renderer debug setting * citra: Make lambda lower case * Consistency with review comments on the PR * video_core: Kill more global state * GetResolutionScaleFactor would be called somewhere in the renderer constructor chain but it relies on the yet unitialized g_renderer, resulting in crashes when the resolution scale is set to auto. Rather than adding a workaround, let's kill this global state to fix this for good
This commit is contained in:
parent
5346ca27b5
commit
ffc95eb59b
17 changed files with 102 additions and 93 deletions
|
@ -74,8 +74,7 @@ System::~System() = default;
|
|||
|
||||
System::ResultStatus System::RunLoop(bool tight_loop) {
|
||||
status = ResultStatus::Success;
|
||||
if (std::any_of(cpu_cores.begin(), cpu_cores.end(),
|
||||
[](std::shared_ptr<ARM_Interface> ptr) { return ptr == nullptr; })) {
|
||||
if (!IsPoweredOn()) {
|
||||
return ResultStatus::ErrorNotInitialized;
|
||||
}
|
||||
|
||||
|
@ -435,7 +434,7 @@ System::ResultStatus System::Init(Frontend::EmuWindow& emu_window,
|
|||
|
||||
LOG_DEBUG(Core, "Initialized OK");
|
||||
|
||||
initalized = true;
|
||||
is_powered_on = true;
|
||||
|
||||
return ResultStatus::Success;
|
||||
}
|
||||
|
@ -537,6 +536,8 @@ void System::Shutdown(bool is_deserializing) {
|
|||
perf_stats ? perf_stats->GetMeanFrametime() : 0);
|
||||
|
||||
// Shutdown emulation session
|
||||
is_powered_on = false;
|
||||
|
||||
VideoCore::Shutdown();
|
||||
HW::Shutdown();
|
||||
if (!is_deserializing) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue