[vlc-commits] PS: fix length computation
Jean-Baptiste Kempf
git at videolan.org
Wed Aug 13 21:40:00 CEST 2014
vlc/vlc-2.2 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Tue Aug 12 03:28:12 2014 +0200| [227c4d268a3fe6bcffa0f29776aa8cbc55df23d4] | committer: Jean-Baptiste Kempf
PS: fix length computation
Should close #9412
Ref #7303 #8180 #7889 #10123 #2608
(cherry picked from commit 2d8e53ac7e404e4ba1b68d70112d991e4adea0a1)
(cherry picked from commit 63a3b568ad2b49778f73d9d8fbec8e281b5f1291)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.2.git/?a=commit;h=227c4d268a3fe6bcffa0f29776aa8cbc55df23d4
---
modules/demux/ps.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/modules/demux/ps.c b/modules/demux/ps.c
index 361d529..e82dbfb 100644
--- a/modules/demux/ps.c
+++ b/modules/demux/ps.c
@@ -258,7 +258,7 @@ static void FindLength( demux_t *p_demux )
stream_Seek( p_demux->s, i_size - i_end );
i = 0;
- while( vlc_object_alive (p_demux) && i < 40 && Demux2( p_demux, true ) > 0 ) i++;
+ while( vlc_object_alive (p_demux) && i < 400 && Demux2( p_demux, true ) > 0 ) i++;
if( i_current_pos >= 0 ) stream_Seek( p_demux->s, i_current_pos );
}
@@ -266,7 +266,7 @@ static void FindLength( demux_t *p_demux )
for( int i = 0; i < PS_TK_COUNT; i++ )
{
ps_track_t *tk = &p_sys->tk[i];
- if( tk->i_first_pts >= 0 && tk->i_last_pts > 0 &&
+ if( tk->i_last_pts > 0 &&
tk->i_last_pts > tk->i_first_pts )
{
int64_t i_length = (int64_t)tk->i_last_pts - tk->i_first_pts;
More information about the vlc-commits
mailing list