[vlc-devel] [PATCH 4/4] demux: ogg: Fix creating index entries before the first existing entry
Michael Tänzer
neo at nhng.de
Sun Jan 31 00:29:25 CET 2016
---
modules/demux/oggseek.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/modules/demux/oggseek.c b/modules/demux/oggseek.c
index e7f3db1..ce9d884 100644
--- a/modules/demux/oggseek.c
+++ b/modules/demux/oggseek.c
@@ -100,12 +100,11 @@ const demux_index_entry_t *OggSeek_IndexAdd ( logical_stream_t *p_stream,
int64_t i_pagepos )
{
demux_index_entry_t *idx;
- demux_index_entry_t *oidx;
demux_index_entry_t *last_idx = NULL;
if ( p_stream == NULL ) return NULL;
- oidx = idx = p_stream->idx;
+ idx = p_stream->idx;
if ( i_timestamp < 1 || i_pagepos < 1 ) return NULL;
@@ -137,8 +136,8 @@ const demux_index_entry_t *OggSeek_IndexAdd ( logical_stream_t *p_stream,
}
else
{
- idx->p_next = oidx;
- oidx = idx;
+ idx->p_next = p_stream->idx;
+ p_stream->idx = idx;
}
if ( idx->p_next != NULL )
--
2.5.0
More information about the vlc-devel
mailing list