Hi,
I'm working on a port for OpenBSD. I can build and run the game (version 0.2.17). But when I exit from the main menu, I get a segfault. gdb shows me this when examining the core file:
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x000009a6995a904b in SDL_DestroyTexture_REAL (texture=0x9a72ca1d8c0)
at /usr/ports/pobj/sdl2-2.32.6/SDL2-2.32.6/src/render/SDL_render.c:4317
4317 CHECK_TEXTURE_MAGIC(texture, );
(gdb) bt
#0 0x000009a6995a904b in SDL_DestroyTexture_REAL (texture=0x9a72ca1d8c0)
at /usr/ports/pobj/sdl2-2.32.6/SDL2-2.32.6/src/render/SDL_render.c:4317
#1 0x000009a43257c572 in cVideo::clearMemory (this=0x9a43260abd8 <Video>)
at /usr/ports/pobj/maxr-0.2.17/maxr-release-0.2.17/src/lib/output/video/video.cpp:73
#2 0x000009a43243fa12 in AtExit::~AtExit (this=<optimized out>)
at /usr/ports/pobj/maxr-0.2.17/maxr-release-0.2.17/src/ui/uimain.cpp:88
#3 0x000009a43243ef4b in main ()
at /usr/ports/pobj/maxr-0.2.17/maxr-release-0.2.17/src/ui/uimain.cpp:169
SDL_DestroyTexture is called at
|
SDL_DestroyTexture (sdlTexture); |
. I suspect that sdlTexture->magic has already been freed, but don't understand the code base well enough to debug further from here. See
changes in SDL3 that are meant to address crashes when freed objects are passed to SDL functions.
Hi,
I'm working on a port for OpenBSD. I can build and run the game (version 0.2.17). But when I exit from the main menu, I get a segfault. gdb shows me this when examining the core file:
SDL_DestroyTextureis called atmaxr/src/lib/output/video/video.cpp
Line 73 in ba4b9d3