3. bug #23026: Crashes when sound is enabled

Having trouble with the game? Report issues and get help here. Read this first!

Moderator: Forum Moderators

Forum rules
Before reporting issues in this section, you must read the following topic:
Post Reply
harl
Posts: 10
Joined: December 13th, 2013, 2:47 pm

3. bug #23026: Crashes when sound is enabled

Post by harl »

Microsoft Windows XP Professional
5.1.2600 Service Pack 3 Build 2600
Wesnoth 1.12.2

Wesnoth crashes at various different points when sound options are enabled (with Windows XP service pack3). This makes multiplayer games with sound effects impossible.

I know this is a previously reported bug but it doesnt seem to be getting much attention so i am reporting it here on the forum too (I am not registered on gna.org/bugs). I see a lot of players in the lobby complaining about their games crashing, I advise some of them to try turning off their sound and a few have reported improvement so this may not be as uncommon an issue as is being assumed. Playing wesnoth with no sound is not as good!

Here are some stderr files generated by crashes,

Sound Effects Enabled: wesnoth crashes at dawn chorus

Battle for Wesnoth v1.12.2
Started on Tue May 05 03:07:34 2015

Automatically found a possible data directory at C:/Program Files/Battle for Wesnoth 1.12.2

Data directory: C:/Program Files/Battle for Wesnoth 1.12.2
User configuration directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
User data directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
Cache directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata\cache
Checking video mode: 1020x726x16...
setting mode to 1020x726x16
20150505 03:08:33 warning unit: Unknown attribute 'no_recruit' discarded.
20150505 03:08:33 warning unit: Unknown attribute 'no_recruit' discarded.
20150505 03:08:40 warning engine: variable_info: retrieving member of non-existent WML container, wct.era_id

Sound Effects Enabled: wesnoth crashes during combat

Battle for Wesnoth v1.12.2
Started on Tue May 05 03:17:37 2015

Automatically found a possible data directory at C:/Program Files/Battle for Wesnoth 1.12.2

Data directory: C:/Program Files/Battle for Wesnoth 1.12.2
User configuration directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
User data directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
Cache directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata\cache
Checking video mode: 1020x726x16...
setting mode to 1020x726x16
20150505 03:19:15 warning unit: Unknown attribute 'no_recruit' discarded.
20150505 03:19:15 warning unit: Unknown attribute 'no_recruit' discarded.[/spoiler]
20150505 03:19:15 warning unit: Unknown attribute 'no_recruit' discarded.
20150505 03:19:15 warning unit: Unknown attribute 'no_recruit' discarded.
20150505 03:19:22 warning engine: variable_info: retrieving member of non-existent WML container, wct.era_id


Music Enabled: No crashes in test.

Turn Bell Enabled: No crashes in test.

User Interface Sounds Enabled: Wesnoth crashes when receiving whispers.

Battle for Wesnoth v1.12.2
Started on Mon May 04 15:54:42 2015

Automatically found a possible data directory at C:/Program Files/Battle for Wesnoth 1.12.2

Data directory: C:/Program Files/Battle for Wesnoth 1.12.2
User configuration directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
User data directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata
Cache directory: C:/Program Files/Battle for Wesnoth 1.12.2\userdata\cache
Checking video mode: 1020x726x16...
setting mode to 1020x726x16
20150504 15:55:32 error config: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
20150504 15:55:32 error config: illegal map: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
The map cannot be loaded.
20150504 15:57:03 error config: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
20150504 15:57:03 error config: illegal map: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
The map cannot be loaded.
20150504 15:57:03 error display: could not open image 'terrain/.png'
20150504 15:59:46 error config: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
20150504 15:59:46 error config: illegal map: Illegal tile in map: (Rr^rG/) 'Rr^rG/'
The map cannot be loaded.
User avatar
Iris
Site Administrator
Posts: 6798
Joined: November 14th, 2006, 5:54 pm
Location: Chile
Contact:

Re: 3. bug #23026: Crashes when sound is enabled

Post by Iris »

I take it that disabling music alone while keeping the rest enabled doesn’t help?
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
User avatar
iceiceice
Posts: 1056
Joined: August 23rd, 2013, 2:10 am

Re: 3. bug #23026: Crashes when sound is enabled

Post by iceiceice »

harl: If I were you, I would try using the lib_vorbis.dll file from the older versions of wesnoth, like this guy did: https://gna.org/bugs/index.php?23203

You can find the download here: http://sourceforge.net/projects/wesnoth ... e%20Stuff/

Don't have windows myself, its hard to be more helpful than that. At least you are on XP so there is less that can go wrong.

Please report back if it works / doesn't work.
harl
Posts: 10
Joined: December 13th, 2013, 2:47 pm

Re: 3. bug #23026: Crashes when sound is enabled

Post by harl »

shadowm wrote:I take it that disabling music alone while keeping the rest enabled doesn’t help?
No. I might not have noticed an issue if that was the case as I rarely have the music enabled. I ran my crash tests with each sound option enabled independently.
iceiceice wrote:harl: If I were you, I would try using the lib_vorbis.dll file from the older versions of wesnoth, like this guy did: https://gna.org/bugs/index.php?23203
I naively replaced the 214k 2014 libvorbis-0.dll with the 154k 2007 libvorbis-0.dll and broke my Wesnoth ;)

"The procedure entry point vorbis_synthesis_idheader could not be located in th dynamic link library libvorbis-0.dll."

I also tried downloading Wesnoth 1.13.0 development version but that has the same issues, probably because it has the same libvorbis-0.dll version as 1.12.2.

I agree that it seems like the same bug as that guy reported so at least it should be resolvable but I am not sure i have the computer wizardry skills required to build a working version of 1.12.2 using the old libvorbis-0.dll. If I try it I will let you know how it turns out.

Thanks for the quick responses.
harl
Posts: 10
Joined: December 13th, 2013, 2:47 pm

Re: 3. bug #23026: Crashes when sound is enabled

Post by harl »

OK, so, I couldnt bring myself to download 3gb of source code and flail around trying to follow complicated procedures with almost zero programming knowledge.... but I think I got lucky.

I replaced both the libvorbis-0.dll and the libvorbisfile-3.dll files with the old versions from the link you provided and now I appear to have a working version of Wesnoth 1.12.2 with sound :)

I am a little concerned that I may encounter other issues resulting from my bodged fix of this bug. Do you think that is likely?

I will update this thread if I run into any errors or crashes that seem related.

Assuming this fix doesnt cause any game breaking problems, I hope it helps all the other xp users who have been playing Wesnoth with no sound!

Thanks again.
User avatar
iceiceice
Posts: 1056
Joined: August 23rd, 2013, 2:10 am

Re: 3. bug #23026: Crashes when sound is enabled

Post by iceiceice »

harl:

That's great!

So, I do have some kind of cross compiling rig set up so that I can make windows binaries, this is from when we were testing all the bugs about non-ascii characters in filepath. http://wiki.wesnoth.org/User:Iceiceice/Cross-compiling

What I was going to do was swap out the dlls and headers for lib vorbis and lib ogg 2007, try to compile it, and post it here. Compiling it takes about 40 minutes.

The trouble is, I don't actually have the bug you mention even with the official libs. So I can't test it myself, it would be a lot of back and forth.

Anyways its really good that just swapping the dll's worked. If you dont have any more problems we should just leave it at that.

---

I unfortunately don't know enough about the internal structure of the libraries to say if you should have a broken build or not. That would be a good question for loonycyborg. (There is also some useful info in that open pandora forums link from the bug tracker mentioned earlier: http://boards.openpandora.org/topic/153 ... orbisfile/)

If you still have problems, the next thing I would try to swap would be lib ogg I guess.

One thing I'm also not sure about is if SDL mixer would need to be recompiled as a result of these changes. I guess that would be the worst case.
User avatar
loonycyborg
Windows Packager
Posts: 295
Joined: April 1st, 2008, 4:45 pm
Location: Russia/Moscow

Re: 3. bug #23026: Crashes when sound is enabled

Post by loonycyborg »

I already don't remember where exactly I took windows dev files for vorbis but it was probably their official dev release. Or from some other SDK that happened to provide it. I can build my own but I'll have trouble reproducing this bug I bet. I'd appreciate if you determined which combination of SDL_mixer/libvorbis/libvorbisfile versions avoids this bug so I would build wesnoth against them next time.
"meh." - zookeeper
harl
Posts: 10
Joined: December 13th, 2013, 2:47 pm

Re: 3. bug #23026: Crashes when sound is enabled

Post by harl »

I have been playing Wesnoth with sound for a week now and I am confident that none of the crashes and bugs I have experienced in the last week were due to my replacement of the libvorbis files :D
loonycyborg wrote:I'd appreciate if you determined which combination of SDL_mixer/libvorbis/libvorbisfile versions avoids this bug so I would build wesnoth against them next time.
I can confirm that the combination of files I am using avoids this bug.

I am using the SDL_mixer.dll that comes bundled with the official (stable) windows version of wesnoth 1.12.2.

I am using the libvorbis-0.dll and the libvorbisfile-3.dll files from the CodeBlocksWinSDK_28_11_2014 zip file downloaded from http://sourceforge.net/projects/wesnoth ... e%20Stuff/ (as linked and suggested by iceiceice).

I would attach these files for your convenience but it seems the extension dll is not allowed as an attachment.
User avatar
loonycyborg
Windows Packager
Posts: 295
Joined: April 1st, 2008, 4:45 pm
Location: Russia/Moscow

Re: 3. bug #23026: Crashes when sound is enabled

Post by loonycyborg »

There's new stable release soon and I'll replace vorbis dlls there with those from Codeblocks SDK then.
"meh." - zookeeper
User avatar
Iris
Site Administrator
Posts: 6798
Joined: November 14th, 2006, 5:54 pm
Location: Chile
Contact:

Re: 3. bug #23026: Crashes when sound is enabled

Post by Iris »

So we tried to fix this in 1.12.4 by downgrading the libraries and that resulted in bug #23671 [Gna.org]. For 1.12.4a, we used even newer libraries instead, and although that fixes #23671 [Gna.org], harl found that it also causes the original bug to resurface.

Any ideas?
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Post Reply