Fix crash

This commit is contained in:
Wojtek Figat
2021-12-11 23:03:37 +01:00
parent f71dce08fc
commit 83046494a5

View File

@@ -414,6 +414,8 @@ void AudioBackendOAL::Source_ClipLoaded(AudioSource* source)
{
auto& contexts = ALC::GetContexts();
const int32 numContexts = contexts.Count();
if (source->SourceIDs.Count() < numContexts)
return;
const auto clip = source->Clip.Get();
const bool is3D = source->Is3D();
const bool isStreamable = clip->IsStreamable();