Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Rare crashes in shipped OpenAL dll  (Read 2905 times)

0 Members and 1 Guest are viewing this topic.

Daid

  • Newbie
  • *
  • Posts: 29
    • View Profile
Rare crashes in shipped OpenAL dll
« on: September 03, 2016, 09:48:27 am »
Simply put, I'm having this issue:
https://github.com/daid/EmptyEpsilon/issues/390

For the last year, my project at http://emptyepsilon.org/ has been growing in the amount of users. But 1 problem seems to persist, depending on the user, I'm getting random crashes in OpenAL.
I've noticed that for the users that do not have this problem, there is actually a different OpenAL.dll in windows/system that is being used instead of the one provided with SFML.

I don't have a specific code example that is triggering this, after all, this is a rare crash. But my code that does sound isn't that complex. It runs a single sf::Music and a maximum of 16 sf::Sound items. The sf::SoundBuffer objects are not moved around in memory. Everything is allocated in the heap. The sf::Music and sf::Sound objects are allocated on start. Everything is single-threaded.
I mixing positional sounds and non-positional sounds.

https://github.com/daid/SeriousProton/blob/master/src/soundManager.cpp



In the end, I cannot think of anything I did wrong in my code anymore. And the problems seems to be gone with a different OpenAL library of which I don't know the origin.
But I don't know the origin of this OpenAL library beyond the fact that they are in the SFML repository and not updated for a while.

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 878
    • View Profile
Re: Rare crashes in shipped OpenAL dll
« Reply #1 on: September 07, 2016, 10:04:31 am »
Replied in the issue.

While still possible, I think a general problem in your code would more likely just crash everywhere.

Which version of SFML are you using for compiling?

binary1248

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1405
  • I am awesome.
    • View Profile
    • The server that really shouldn't be running
Re: Rare crashes in shipped OpenAL dll
« Reply #2 on: September 07, 2016, 10:24:56 am »
A bunch of stuff has been fixed in OpenAL soft since 1.15.1 (the version SFML supplies):

https://github.com/kcat/openal-soft/blob/master/ChangeLog

Might be worth updating our copy of the library at some point.
SFGUI # SFNUL # GLS # Wyrm <- Why do I waste my time on such a useless project? Because I am awesome (first meaning).

Daid

  • Newbie
  • *
  • Posts: 29
    • View Profile
Re: Rare crashes in shipped OpenAL dll
« Reply #3 on: September 07, 2016, 10:58:14 am »
Replied in the issue.

While still possible, I think a general problem in your code would more likely just crash everywhere.

Which version of SFML are you using for compiling?
I'm using 2.3.1, with a slight patch for Android:
Code at: https://github.com/daid/SFML

I've compiled SFML and the final executable with the same compiler which is:
daid@black:~/ee/EmptyEpsilon/_build_win32$ i686-w64-mingw32-gcc --version
i686-w64-mingw32-gcc (GCC) 4.8.2
Copyright (C) 2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 

SFML is build as "Release", my own application as "RelWithDebInfo"

I'm linking in drmingw 0.7.7 for post-mortom crash debugging.
https://github.com/jrfonseca/drmingw

(Which made it easier to trace down the crashes happening in OpenAL.dll and not somewhere in my own code)

Mario

  • SFML Team
  • Hero Member
  • *****
  • Posts: 878
    • View Profile
Re: Rare crashes in shipped OpenAL dll
« Reply #4 on: September 07, 2016, 11:05:37 am »
Yeah, next step I'd try using the latest version of OpenAL Soft instead to see whether it fixes the issue. Grabbing the binary should be enough, but you could also recompile it yourself.