forked from mirror/openmw-tes3mp
Reset the sound handle back to null after unloading
This commit is contained in:
parent
4801661b34
commit
fd7d58fe7e
1 changed files with 3 additions and 0 deletions
|
@ -225,8 +225,11 @@ namespace MWSound
|
|||
}
|
||||
SoundSet::iterator iter = mUnusedBuffers.begin();
|
||||
Sound_Buffer *unused = &mSoundBuffers[*iter];
|
||||
|
||||
mBufferCacheSize -= mOutput->getSoundDataSize(unused->mHandle);
|
||||
mOutput->unloadSound(unused->mHandle);
|
||||
unused->mHandle = 0;
|
||||
|
||||
mUnusedBuffers.erase(iter);
|
||||
}
|
||||
mUnusedBuffers.insert(sfxid);
|
||||
|
|
Loading…
Reference in a new issue