[NUT-devel] [nut]: r153 - trunk/libnut/demuxer.c
ods15
subversion at mplayerhq.hu
Sun Sep 24 14:07:19 CEST 2006
Author: ods15
Date: Sun Sep 24 14:07:19 2006
New Revision: 153
Modified:
trunk/libnut/demuxer.c
Log:
fix long withstanding bug by seeking to headers when going past BOF
instead of to syncpoint.
Modified: trunk/libnut/demuxer.c
==============================================================================
--- trunk/libnut/demuxer.c (original)
+++ trunk/libnut/demuxer.c Sun Sep 24 14:07:19 2006
@@ -734,7 +734,7 @@
if (tmp == MAIN_STARTCODE) break;
}
ERROR(tmp != MAIN_STARTCODE, -ERR_NO_HEADERS);
- nut->last_headers = bctello(nut->i);
+ nut->last_headers = bctello(nut->i) - 8;
flush_buf(nut->i);
}
@@ -919,8 +919,7 @@
goto err_out;
}
if (i == 0) { // there isn't any syncpoint smaller than requested
- int FIXME; // pos might not be accurate - if this function is called when there really is an index
- seek_buf(nut->i, sl->s[0].pos, SEEK_SET); // seeking to first syncpoint
+ seek_buf(nut->i, nut->last_headers, SEEK_SET); // seeking to "begginning of file", the headers
clear_dts_cache(nut);
nut->last_syncpoint = 0;
goto err_out;
More information about the NUT-devel
mailing list