[Scummvm-tracker] [ScummVM :: Bugs] #12649: SCUMM: Deadlock in Player_AD on quitting

ScummVM :: Bugs trac at scummvm.org
Mon Jun 21 15:17:46 UTC 2021


#12649: SCUMM: Deadlock in Player_AD on quitting
-------------------------+----------------------------
Reporter:  eriktorbjorn  |       Owner:  (none)
    Type:  defect        |      Status:  new
Priority:  normal        |   Component:  Engine: SCUMM
 Version:                |  Resolution:
Keywords:                |        Game:
-------------------------+----------------------------
Comment (by athrxx):

 I was more about improving the common code in common/mutex.h/.cpp. But
 your changes are completely fine for this situation here. So I am all for
 pushing these commits...

 I have done some testing with Loom EGA. Managed to reproduce the issue
 right away. The SDL audio thread got trapped in Player_AD::onTimer(), the
 main thread got trapped in MixerImpl::stopHandle(). So that seems exactly
 what you got...

 With your 2 commits on top of that the issue seems to be fixed. In my test
 the SDL audio thread was held in MixerImpl::mixCallback() during the
 ~Player_AD destruction after the mutex lock, so that seems to be exactly
 as it should...

 I have some other sound drivers which use the mixer thread and have their
 own mutexes. After you push your commits I'll try to get rid of some of
 these, too.
-- 
Ticket URL: <https://bugs.scummvm.org/ticket/12649#comment:3>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM


More information about the Scummvm-tracker mailing list