stransky / berusky2

Berusky 2 (Bugs Escape 3D) is a game that challenges your visual/spatial thinking and ability to find a way to resolve a logic task. Using five bugs, you'll go through an adventure full of various puzzles spread across nine episodes. Individual episodes differ in appearance and difficulty, which increases throughout the game.
http://anakreon.cz/en/Berusky2.htm
GNU General Public License v3.0
14 stars 3 forks source link

berusky2: Segfault in XSync on exit #18

Open apoleon opened 11 years ago

apoleon commented 11 years ago

Hi!

This is Debian bug http://bugs.debian.org/722639

At some point when existing the game it crashes with a segmentation fault.

The backtrace for that core dump is:

Core was generated by `berusky2'. Program terminated with signal 11, Segmentation fault.

0 XSync (dpy=0x0, discard=discard@entry=0) at ../../src/Sync.c:42

42 ../../src/Sync.c: No such file or directory. (gdb) bt full

0 XSync (dpy=0x0, discard=discard@entry=0) at ../../src/Sync.c:42

    rep = {type = 168 '\250', revertTo = 149 '\225', 
      sequenceNumber = 31744, length = 32546, focus = 2087582160, 
      pad1 = 32546, pad2 = 0, pad3 = 0, pad4 = 0, pad5 = 0}

1 0x00007f227c044478 in X11_VideoQuit (this=0x1bb5dc0)

at ../../src/video/x11/SDL_x11video.c:1491

No locals.

2 0x00007f227c036c3e in SDL_VideoQuit () at ../../src/video/SDL_video.c:1365

    video = 0x1bb5dc0
    this = 0x1bb5dc0
    ready_to_go = <optimized out>

3 0x00007f227c0111d5 in SDL_QuitSubSystem (flags=flags@entry=65535)

at ../../src/SDL.c:196

No locals.

4 0x00007f227c01127e in SDL_Quit () at ../../src/SDL.c:222

No locals.

5 0x00007f227c0118bf in SDL_Parachute (sig=11) at ../../src/SDL_fatal.c:41

No locals.

6

No locals.

7 0x000000000055957c in ?? ()

No symbol table info available.

8 0x00007f227ad57e0e in start_thread (arg=0x7f226ecf6700)

at pthread_create.c:311
    __res = <optimized out>
    pd = 0x7f226ecf6700
    now = <optimized out>
    unwind_buf = {cancel_jmp_buf = {{jmp_buf = {139785864701696, 
            -124161288581994295, 0, 139786066463968, 4096, 
            139785864701696, 631574938200265, 587541738236105}, 
          mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, 
        data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
    not_first_call = 0
    pagesize_m1 = <optimized out>
    sp = <optimized out>
    freesize = <optimized out>
    __PRETTY_FUNCTION__ = "start_thread"

9 0x00007f227a27593d in clone ()

at ../sysdeps/unix/sysv/linux/x86_64/clone.S:113

No locals.

This segfault might be related to some kind of threading issue. See also the next bug report about the "Abort in XCB code".

stransky commented 11 years ago

It's a segfault in the tread code, handled by SDL_Parachute(). The rest (Xsync failure) is just a follow up failure. The core will abort/crash even when XInitThreads() is called.