[vlc-commits] [Git][videolan/vlc][master] demux: aiff: do not try to read a file if seeking is not possible

Steve Lhomme (@robUx4) gitlab at videolan.org
Fri Aug 14 14:17:04 UTC 2026



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
85d72b30 by Steve Lhomme at 2026-08-14T13:55:17+00:00
demux: aiff: do not try to read a file if seeking is not possible

The AIFF parser parses the file until the end (skipping the chunks data) and
then seeks to the beginning of the SSND chunk. If seeking is not possible we
can't do that.

- - - - -


1 changed file:

- modules/demux/aiff.c


Changes:

=====================================
modules/demux/aiff.c
=====================================
@@ -168,6 +168,14 @@ static int Open( vlc_object_t *p_this )
     demux_t     *p_demux = (demux_t*)p_this;
     demux_sys_t *p_sys;
 
+    bool b_canseek = false;
+    vlc_stream_Control( p_demux->s, STREAM_CAN_SEEK, &b_canseek );
+    if (!b_canseek)
+    {
+        msg_Err( p_demux, "AIFF parsing requires seeking" );
+        return VLC_EGENERIC;
+    }
+
     const uint8_t *p_peek;
 
     if( vlc_stream_Peek( p_demux->s, &p_peek, 12 ) < 12 )



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/85d72b307397f56de8b9209b5cca7ec9c6a63463

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/85d72b307397f56de8b9209b5cca7ec9c6a63463
You're receiving this email because of your account on code.videolan.org. Manage all notifications: https://code.videolan.org/-/profile/notifications | Help: https://code.videolan.org/help




More information about the vlc-commits mailing list