Clear unneeded variables upon stopping emulation.
This commit is contained in:
parent
d26c7fea17
commit
0c6dad6a37
|
@ -293,7 +293,7 @@ void Stop() // - Hammertime!
|
||||||
SConfig::GetInstance().m_SYSCONF->Reload();
|
SConfig::GetInstance().m_SYSCONF->Reload();
|
||||||
|
|
||||||
INFO_LOG(CONSOLE, "Stop [Main Thread]\t\t---- Shutdown complete ----");
|
INFO_LOG(CONSOLE, "Stop [Main Thread]\t\t---- Shutdown complete ----");
|
||||||
Movie::g_currentInputCount = 0;
|
Movie::Shutdown();
|
||||||
g_bStopping = false;
|
g_bStopping = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -163,10 +163,6 @@ void Init()
|
||||||
g_currentFrame = 0;
|
g_currentFrame = 0;
|
||||||
g_currentLagCount = 0;
|
g_currentLagCount = 0;
|
||||||
g_currentInputCount = 0;
|
g_currentInputCount = 0;
|
||||||
// we don't clear these things because otherwise we can't resume playback if we load a movie state later
|
|
||||||
//g_totalFrames = g_totalBytes = 0;
|
|
||||||
//delete tmpInput;
|
|
||||||
//tmpInput = NULL;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
std::thread md5thread(CheckMD5);
|
std::thread md5thread(CheckMD5);
|
||||||
|
@ -1186,4 +1182,11 @@ void CheckMD5()
|
||||||
Core::DisplayMessage("Finished calculating checksum.", 2000);
|
Core::DisplayMessage("Finished calculating checksum.", 2000);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Shutdown()
|
||||||
|
{
|
||||||
|
g_currentInputCount = g_totalInputCount = g_totalFrames = g_totalBytes = 0;
|
||||||
|
delete [] tmpInput;
|
||||||
|
tmpInput = NULL;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -177,6 +177,7 @@ void EndPlayInput(bool cont);
|
||||||
void SaveRecording(const char *filename);
|
void SaveRecording(const char *filename);
|
||||||
void DoState(PointerWrap &p);
|
void DoState(PointerWrap &p);
|
||||||
void CheckMD5();
|
void CheckMD5();
|
||||||
|
void Shutdown();
|
||||||
|
|
||||||
std::string GetInputDisplay();
|
std::string GetInputDisplay();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue