SDL_mixer icon indicating copy to clipboard operation
SDL_mixer copied to clipboard

Debugger crashes when debugging with SDL_INIT_AUDIO flag

Open hsbgit opened this issue 3 years ago • 2 comments

This is my current setup:

Description: Ubuntu 20.04.3 LTS Release: 20.04 Codename: focal Running in a virtualbox

I am using the official SDL2 packages from the Ubuntu repos -> libsdl2-mixer-2.0-0

I am working with QtCreator (C++) and have an interesting behavior: In release mode, everything runs as expected (also music/sounds). But if I run debug mode (and it is actually the debug mode/build!) the application crashes inside SDL_Init. SDL_Init is the very first function that I call in main().

I figured out that the crash is somehow related to the SDL_INIT_AUDIO flag. If I omit this flag, there is no crash and I can debug (of course all further Mixer calls result in a crash...).

sdl_audio_debug_crash

hsbgit avatar Dec 07 '21 08:12 hsbgit

Can you build a debug version of SDL and use a debugger to see what's happening?

slouken avatar Dec 07 '21 15:12 slouken

It may take some time as I am currently quite busy... but I will try

hsbgit avatar Dec 09 '21 15:12 hsbgit