Melchior FRANZ:
At last I've found the reason why fgfs crashed routinely for me. When I still used KDE's artsdsp (preloads lib with OSS replacement functions) I saw this crash only occasionally. After letting OpenAl communicate with artsd directly (by means of ~/.openalrc setting), I got the crash always when I left fgfs. This bug may also have crashed fgfs when running with sound daemons other than aRts.
This commit is contained in:
@@ -69,7 +69,8 @@ SGSoundMgr::SGSoundMgr() {
|
||||
|
||||
// initialize OpenAL
|
||||
alutInit( 0, NULL );
|
||||
alGetError();
|
||||
atexit(alutExit);
|
||||
|
||||
if ( alGetError() == AL_NO_ERROR) {
|
||||
working = true;
|
||||
} else {
|
||||
@@ -119,8 +120,6 @@ SGSoundMgr::~SGSoundMgr() {
|
||||
SGSoundSample *sample = sample_current->second;
|
||||
delete sample;
|
||||
}
|
||||
|
||||
alutExit();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -80,11 +80,8 @@ SGXmlSound::~SGXmlSound()
|
||||
{
|
||||
_sample->stop();
|
||||
|
||||
if (_property)
|
||||
delete _property;
|
||||
|
||||
if (_condition)
|
||||
delete _condition;
|
||||
delete _property;
|
||||
delete _condition;
|
||||
|
||||
_volume.clear();
|
||||
_pitch.clear();
|
||||
|
||||
Reference in New Issue
Block a user