albertz / openlierox

OpenLieroX - Liero clone / Worms realtime / 2D shooter
http://openlierox.net
Other
265 stars 61 forks source link

[0.58; SDL?] Crash when loading Shock v1.40 Air mod (invalid sound file format?) #817

Open lxkurko opened 6 years ago

lxkurko commented 6 years ago

0.58, compiled from current Github source, seems to crash when trying to start a game or adjust weapon bans when the Shock v1.40 Air mod is selected. This does not happen on all systems, and I suspect that this might be related to SDL.

Console output when starting the game: https://bpaste.net/show/a88b22afa3fa

Console output when trying to open the weapon options dialog: https://bpaste.net/show/bd34628adae6

These are apparently the last messages before the crash:

[23:21:00] n: LoadSoundSample: Error while loading ./../gamedata-058/Shock v1.40 Air/sfx/Hammer.wav: MPEG Layer 3 data not supported [23:21:00] n: modLog: Could not open sound 'Hammer.wav'

Checking that file with the "file" command shows that it has different or malformed contents: Grenade.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 8 bit, mono 11025 Hz Hammer.wav: RIFF (little-endian) data, WAVE audio, MPEG Layer 3, mono 8000 Hz Launch.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 8 bit, mono 22050 Hz

If the file is converted to raw WAV format, e.g. by using VLC, the game does not crash.

This crash does occur on Fedora 27, with the following SDL(1) library versions installed: 1.2.15-29.fc27 (main) 1.2.12-17.fc27 (image) 1.2.12-14.fc27 (mixer) 1.2.8-11.fc27 (net) 1.0.3-19.fc27 (sound)

This does NOT apparently occur on Debian 9 with the following SDL(1) versions installed. Instead, the error message is printed three times (Hammer.wav is also mentioned three times in the .lgs file) and the default sound effect is used instead. 1.2.12-5+deb9u1 (image) 1.2.12-11+b3 (mixer) 1.2.15+dfsg1-4 (main) 1.0.3-7+b3 (sound)

This does NOT occur with 0.59 - it can apparently read the file without problems. It uses SDL2.

Similar crashes related to Shock v1.40 Air were reported several years ago but I do not have any logs about these. An SDL update apparently fixed the problem back then.

pelya commented 6 years ago

Yup, mp3 format is patent-free now, so new versions of SDL_mixer support it by default.

On Sat, 5 May 2018 00:01 lxkurko notifications@github.com wrote:

0.58, compiled from current Github source, seems to crash when trying to start a game or adjust weapon bans when the Shock v1.40 Air mod is selected. This does not happen on all systems, and I suspect that this might be related to SDL.

Console output when starting the game: https://bpaste.net/show/a88b22afa3fa

Console output when trying to open the weapon options dialog: https://bpaste.net/show/bd34628adae6

These are apparently the last messages before the crash:

[23:21:00] n: LoadSoundSample: Error while loading ./../gamedata-058/Shock v1.40 Air/sfx/Hammer.wav: MPEG Layer 3 data not supported [23:21:00] n: modLog: Could not open sound 'Hammer.wav'

Checking that file with the "file" command shows that it has different or malformed contents: Grenade.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 8 bit, mono 11025 Hz Hammer.wav: RIFF (little-endian) data, WAVE audio, MPEG Layer 3, mono 8000 Hz Launch.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 8 bit, mono 22050 Hz

If the file is converted to raw WAV format, e.g. by using VLC, the game does not crash.

This crash does occur on Fedora 27, with the following SDL(1) library versions installed: 1.2.15-29.fc27 (main) 1.2.12-17.fc27 (image) 1.2.12-14.fc27 (mixer) 1.2.8-11.fc27 (net) 1.0.3-19.fc27 (sound)

This does NOT apparently occur on Debian 9 with the following SDL(1) versions installed. Instead, the error message is printed three times (Hammer.wav is also mentioned three times in the .lgs file) and the default sound effect is used instead. 1.2.12-5+deb9u1 (image) 1.2.12-11+b3 (mixer) 1.2.15+dfsg1-4 (main) 1.0.3-7+b3 (sound)

This does NOT occur with 0.59 - it can apparently read the file without problems. It uses SDL2.

Similar crashes related to Shock v1.40 Air were reported several years ago but I do not have any logs about these. An SDL update apparently fixed the problem back then.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/albertz/openlierox/issues/817, or mute the thread https://github.com/notifications/unsubscribe-auth/AAJewHsHoeiAgYXwOKsneNm7ouvS-zUoks5tvMGcgaJpZM4TzRBE .