[vlc-commits] [Git][videolan/vlc][master] aaudio: fix assert after restart

Steve Lhomme (@robUx4) gitlab at videolan.org
Wed May 14 11:52:24 UTC 2025



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
4ea4bfb2 by Thomas Guillem at 2025-05-14T11:07:55+00:00
aaudio: fix assert after restart

E  [ee43a9e0/bab] libvlc generic: AAudio stream error or disconnected:: AAUDIO_ERROR_DISCONNECTED
D  [ee18feb0/bab] libvlc audio output: restart requested (7)
W  onMoreData() data, stream disconnected
E  processAudioBuffer(26): EVENT_MORE_DATA requested 8208 bytes but callback returned -1 bytes
E  ../../modules/audio_output/android/aaudio.c:681: void Play(aout_stream_t *, vlc_frame_t *, vlc_tick_t): assertion "state == AAUDIO_STREAM_STATE_STARTING || state == AAUDIO_STREAM_STATE_STARTED" failed

- - - - -


1 changed file:

- modules/audio_output/android/aaudio.c


Changes:

=====================================
modules/audio_output/android/aaudio.c
=====================================
@@ -668,13 +668,9 @@ Play(aout_stream_t *stream, vlc_frame_t *frame, vlc_tick_t date)
         if (RequestStart(stream) != VLC_SUCCESS)
             goto bailout;
     }
-    else if (state == AAUDIO_STREAM_STATE_UNINITIALIZED)
+    else if (state != AAUDIO_STREAM_STATE_STARTING
+          && state != AAUDIO_STREAM_STATE_STARTED)
         goto bailout;
-    else
-    {
-        assert(state == AAUDIO_STREAM_STATE_STARTING
-            || state == AAUDIO_STREAM_STATE_STARTED);
-    }
 
     assert(sys->as);
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/4ea4bfb2a4dc3ea31ec663105c74fa1061decf23

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/4ea4bfb2a4dc3ea31ec663105c74fa1061decf23
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list