[Scummvm-tracker] [ScummVM :: Bugs] #17188: The Dig (Macintosh) crashes after R2D2 scream on Lucasarts animation logo after the ending credits
ScummVM :: Bugs
trac at scummvm.org
Mon Sep 14 10:15:46 UTC 2026
#17188: The Dig (Macintosh) crashes after R2D2 scream on Lucasarts animation logo
after the ending credits
----------------------------------+----------------------------
Reporter: filipetolhuizen | Owner: (none)
Type: defect | Status: new
Priority: high | Component: Engine: SCUMM
Version: | Resolution:
Keywords: The Dig Mac Macintosh | Game: The Dig
----------------------------------+----------------------------
Comment (by eriktorbjorn):
I can reproduce it, though it's ''probably'' not unique to the Macintosh
version. It appears to be a fairly straightforward "use-after-free" bug,
where an object is freed but there's still a variable pointing to the
memory area where it used to be.
I think this is the proper fix:
{{{
diff --git a/engines/scumm/scumm.cpp b/engines/scumm/scumm.cpp
index d816ca77d5f..8771959b194 100644
--- a/engines/scumm/scumm.cpp
+++ b/engines/scumm/scumm.cpp
@@ -477,6 +477,7 @@ ScummEngine::ScummEngine(OSystem *syst, const
DetectorResult &dr)
ScummEngine::~ScummEngine() {
delete _musicEngine;
+ _musicEngine = _imuseDigital = nullptr;
// Delete the sound object earlier than the actors
// for HE games, since in SoundHE::stopAllSounds() we
}}}
Though I should ask someone else to look before committing it. (Which I
can't easily do from this computer anyway.)
--
Ticket URL: <https://bugs.scummvm.org/ticket/17188#comment:1>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM
More information about the Scummvm-tracker
mailing list