summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaganty Rushyendra <mrushyendra@yahoo.com.sg>2021-04-24 11:06:28 -0400
committerMaganty Rushyendra <mrushyendra@yahoo.com.sg>2021-04-24 11:22:19 -0400
commitccc375f16334d0eb8d56d5e5f2b248ef1ee55258 (patch)
tree015c7b4315ad42b67cf4dbeb946799c68033fc2c
parentdb90ab86b94eb59eb296d574c279e40e57c2f99b (diff)
Fix AudioServer Crash when bus count equals 0
-rw-r--r--servers/audio_server.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/servers/audio_server.cpp b/servers/audio_server.cpp
index 138cb6e1f8..08c482553b 100644
--- a/servers/audio_server.cpp
+++ b/servers/audio_server.cpp
@@ -246,6 +246,7 @@ void AudioServer::_driver_process(int p_frames, int32_t *p_buffer) {
init_channels_and_buffers();
}
+ ERR_FAIL_COND_MSG(buses.is_empty() && todo, "AudioServer bus count is less than 1.");
while (todo) {
if (to_mix == 0) {
_mix_step();