From a3e81f3f5741799f6e37b6dc4fdd86b201cbfb11 Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Thu, 12 Aug 2021 11:54:24 +1000 Subject: [PATCH] Fix OpenAL backend crashing when sounds is initially 0 due to my mistakes --- src/Audio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Audio.c b/src/Audio.c index 20b54aeca..b9dc13a82 100644 --- a/src/Audio.c +++ b/src/Audio.c @@ -255,7 +255,7 @@ cc_result Audio_Play(struct AudioContext* ctx) { } static void AudioBackend_Stop(struct AudioContext* ctx) { - if (ctx->source == -1) return; + if (!ctx->source) return; _alSourceStop(ctx->source); _alGetError();