summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorFabio Iotti <fabiogiopla@gmail.com>2020-02-04 21:11:38 +0000
committerFabio Iotti <fabiogiopla@gmail.com>2020-02-04 21:11:38 +0000
commit5ed4ad81c3892c73bd53abffe98dc5910f04c23c (patch)
tree7853e464ea1036f45328be725e83212f8837f7fa /modules
parentc4daac279b8ec6f4893056ba6717624f701ab970 (diff)
Fix empty audio infinite loop
Diffstat (limited to 'modules')
-rw-r--r--modules/stb_vorbis/audio_stream_ogg_vorbis.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
index b80b126bde..f2d0f5c9a6 100644
--- a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
+++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp
@@ -57,7 +57,7 @@ void AudioStreamPlaybackOGGVorbis::_mix_internal(AudioFrame *p_buffer, int p_fra
if (todo) {
//end of file!
- if (vorbis_stream->loop) {
+ if (vorbis_stream->loop && mixed > 0) {
//loop
seek(vorbis_stream->loop_offset);
loops++;