Opened 8 years ago

Closed 7 years ago

Last modified 5 years ago

#9630 closed defect (fixed)

SDL2: Crashes when using MT-32 emulation

Reported by: domino1983 Owned by: wjp
Priority: normal Component: Ports
Version: Keywords:
Cc: Game:

Description

The latest Win32 daily build (October 24, 2016, 10:34 pm) seems to have problem with that game. It crashes when trying to start. It's CD/DOS/English version.
It works without problems with latest official build and it worked without problems with some older daily build (week ago).

Change History (11)

comment:1 by Kirben, 7 years ago

The crash is caused by SDL 2.0.5. but I'm unable to get a useful back trace via MinGW.

comment:2 by OmerMor, 7 years ago

I tried to build from the source w/VS2015 using the wiki instructions, but it appears to be using SDL1 and not SDL2.

If you could update the instructions, I would be able to help get a stack trace.

comment:3 by dreammaster, 7 years ago

That's correct. Although support for SDL2 has been added previously, by LordHoto I think, I'm pretty sure it does indeed still link to SDL1. Given the recent problems with SDL2, I didn't see much point in updating the project creation to use SDL2 by default yet.

You should be able to go to dists/msvc14/create_msvc14.bat, and copy either of the stable or all engines lines that call create_project, and simply add "-use-sdl2" as an extra parameter. From memory, that should allow you to generate project files that link against SDL2. As has been previously mentioned, SDL 2.0.4 DLL is being provided with the libs package, so you'd also need to get the 2.0.5 and replace the DLL.

Last edited 7 years ago by wjp (previous) (diff)

comment:4 by wjp, 7 years ago

I think the MT-32 emu might be calling OSD functions in the audio thread. (See also #9609)

comment:5 by criezy, 7 years ago

If OSD is the issue then PR 855 should fix it. I was planning to merge it into master this weekend (after taking the time to look at the comment from fuzzie) but not into the 1.9 branch since cloud is not enabled there anyway. But if this fixes this bug I will revise that plan.

comment:6 by Kirben, 7 years ago

I tried adding ​PR 855, but the crash still occurs.

comment:7 by Kirben, 7 years ago

Component: Engine: Kyra--Unset--
Game: Kyrandia 1
Summary: KYRA: Legend of Kyrandia Book I crashes when using MT-32 emulationSDL2: Crashes when using MT-32 emulation

comment:8 by eriktorbjorn, 7 years ago

There's also this SDL bug: https://bugzilla.libsdl.org/show_bug.cgi?id=3584

So presumably it will work with their next release, whenever that is.

comment:9 by wjp, 7 years ago

Munt 2.0.3 also reduces its stack footprint ( https://sourceforge.net/p/munt/bugs/28/ ). I've now updated our internal version to this, so hopefully this is now resolved, even with SDL-2.0.5.

comment:10 by csnover, 7 years ago

Owner: set to wjp
Resolution: fixed
Status: newclosed

I have not seen any reports of this being a problem since the Munt update, so I’m going to mark this ticket as resolved for now. Please feel free to comment or reopen if anything changes.

comment:11 by digitall, 5 years ago

Component: --Unset--Ports
Note: See TracTickets for help on using tickets.