Skip to content
  • Vincent Penquerc'h's avatar
    Do not delay processing of the first data page of the last logical stream · 442eb5a4
    Vincent Penquerc'h authored
    
    
    The first data page of a physical stream is stored in the relevant logical stream
    in Ogg_FindLogicalStreams. Therefore, we must not read a page and only update the
    stream it belongs to if we haven't processed this first page yet. If we do, we
    will only process that first page whenever we find the second page for this stream.
    While this is fine for Vorbis and Theora, which are continuous codecs, which means
    the second page will arrive real quick, this is not fine for Kate, whose second
    data page will typically arrive much later.
    This means it is now possible to seek right at the start of a stream where the last
    logical stream is Kate, without having to wait for the second data page to unblock
    the first one, which is the one that triggers the 'no more headers to backup' code.
    And, as we all know, seeking without having backed up all headers is bad, since the
    codec will fail to initialize if it's missing its headers.
    
    Signed-off-by: default avatarLaurent Aimar <fenrir@videolan.org>
    442eb5a4