#12 No sound or crash with libmodplug 0.8.8

open-accepted
Konstanty
None
5
2010-04-10
2010-04-07
Ville Skyttä
No

After upgrading to libmodplug 0.8.8 on Fedora 13 x86_64, xine-lib (1.18) crashes when trying to play something using libmodplug, and modplugplay does not crash but there's no sound. Reverting back to 0.8.7 fixes both issues.

Discussion

  • Konstanty
    Konstanty
    2010-04-10

    • assigned_to: nobody --> metaplasma
    • status: open --> open-accepted
     
  • Konstanty
    Konstanty
    2010-04-10

    I have the same problem with xine-lib on fedora 12.

    VLC and gstreamer (totem) work fine though.
    modplugplay doesn't play for me due to no OSS compatibility mode. I have a modplug123 which allows exporting to file.

    Looking for a backtrace of the crash atm (installing debuginfo)
    (gdb) bt
    #0 0x0000003b3ea7f2f2 in __strlen_sse2 () from /lib64/libc.so.6
    #1 0x0000003b3ea7f016 in strdup () from /lib64/libc.so.6
    #2 0x00007fffd7edfd21 in ?? ()
    from /usr/lib64/xine/plugins/1.26/xineplug_dmx_audio.so
    #3 0x00007fffd7edfec5 in ?? ()
    from /usr/lib64/xine/plugins/1.26/xineplug_dmx_audio.so
    #4 0x0000003b40219d86 in ?? () from /usr/lib64/libxine.so.1
    #5 0x0000003b40211acd in xine_open () from /usr/lib64/libxine.so.1

     
  • Konstanty
    Konstanty
    2010-04-10

    It seems it is because of libmodplug adding two new members to the settings variable.

    gstreamer seems OK because it uses the C++ interface - however still working out why vlc is OK wit this.

     
  • Ville Skyttä
    Ville Skyttä
    2010-04-10

    You can try modplugplay with aoss, install alsa-oss and run "aoss modplugplay foo.mod" or link it with libaoss when compiling (that's what I've just done in the Fedora development modplugplay package).

     
  • Frank Wille
    Frank Wille
    2010-04-11

    I have just fixed it locally, after some debugging. The new gSettings members mStereoSeparation and mMaxMixChannels are both initially zero. They need to be 128 and 32 in modplug.cpp, otherwise you will first need to set the manually with calling ModPlug::setSettings.

     
  • Ville Skyttä
    Ville Skyttä
    2010-04-11

    Confirmed partially, setting them to 128 and 32 in modplug.cpp makes sound come out of modplugplay again. Xine based players still crash though (tried with dragon, kaffeine, and xine-ui).

     
  • Ville Skyttä
    Ville Skyttä
    2010-04-11

    For clarity, libmodplug-0.8.8-defaults.patch is the patch I tested with.

     
  • Ville Skyttä
    Ville Skyttä
    2010-04-12

    Doesn't this mean that this is a backwards incompatible ABI change and so the soname of libmodplug should be increased (e.g. from 0 to 1)?

     
  • Ville Skyttä
    Ville Skyttä
    2010-05-09

    I've tested some more (with the same patch as before) on Fedora 13 x86_64:
    - OK, no rebuild needed: SDL_sound, xmms-modplug, gstreamer-plugins-bad, qmmp, modplugplay
    - Crash without a rebuild, OK after rebuild: xine-lib

    The only thing left broken of what I've tested is xmms2, updating libmodplug to 0.8.8 causes silence from it no matter if it's built against 0.8.7 or 0.8.8. Peeking into the xmms2 source it seems to call ModPlug_SetSettings before ModPlug_Load so I suppose it's something else than what caused problems in modplugplay.
    http://git.xmms.se/?p=xmms2-devel.git;a=blob;f=src/plugins/modplug/modplug.c