mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-08 10:51:11 +00:00
ENGINES: Disallow assignment to a busy pause token.
This commit is contained in:
parent
8079dc8d72
commit
f5ac623cca
@ -836,12 +836,8 @@ PauseToken::PauseToken() : _engine(nullptr) {}
|
||||
PauseToken::PauseToken(Engine *engine) : _engine(engine) {}
|
||||
|
||||
void PauseToken::operator=(const PauseToken &t2) {
|
||||
if (t2._engine == _engine) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (_engine) {
|
||||
_engine->resumeEngine();
|
||||
error("Tried to assign to an already busy PauseToken");
|
||||
}
|
||||
_engine = t2._engine;
|
||||
if (_engine) {
|
||||
|
Loading…
Reference in New Issue
Block a user