I need help to pinpoint the crash culprit in my app, I'm using kubuntu
with openal 1.4.272.
I'm streaming an ogg music to the openal and if I do an unload and
load another music it works, but when I call the same unload method
from window close event (before any openal deinit) it crashes inside
openal alDeleteBuffers when trying to "free" the second buffer data
(and I don't found if it is really related to closing window it is
just the way I can reproduce).
This is my Unload method:
void Music::Unload()
{
if (!this->bLoaded)
return;
ALenum err = AL_NO_ERROR;
if (this->iSource)
{
int queued = 0;
alGetSourcei(iSource, AL_BUFFERS_QUEUED, &queued);
err = alGetError();
while (queued--)
{
ALuint buffer;
alSourceUnqueueBuffers(this->iSource, 1, &buffer);
err = alGetError();
}
alDeleteSources(1, &iSource);
err = alGetError();
this->iSource = 0;
}
alDeleteBuffers(OPENAL_MUSIC_BUFFERS, iBuffers); // crash here
err = alGetError();
memset(iBuffers, '\0', OPENAL_MUSIC_BUFFERS);
ov_clear(&oggStream);
stFile.Close();
this->bLoaded = FALSE;
}
I downloaded the source code from openal soft and debugged inside it
(and tried the lastest release 1.8.466 too), both crashed at
alBuffer.c line 189 but only for the second iteration (second buffer
handle). As openal makes a copy of my pcm data I really don't think
that it has anything to do with the ogg streaming.
Last week I tested it on Windows and it was not crashing, but I will
do some testing with MacOSX and Windows as soon as possible to be
sure.
Thank you
--
Animal Liberation Front
http://www.animal-liberation.com/_______________________________________________
Openal mailing list
Openal@...
http://opensource.creative.com/mailman/listinfo/openal