changeset 20464:7b8269775ec0

10l: fixed misplaced adaption field check
author nicodvb
date Sat, 28 Oct 2006 09:03:51 +0000
parents c983ef46ce3e
children 367513ea7b12
files libmpdemux/demux_ts.c
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/demux_ts.c	Sat Oct 28 08:56:44 2006 +0000
+++ b/libmpdemux/demux_ts.c	Sat Oct 28 09:03:51 2006 +0000
@@ -2622,6 +2622,12 @@
 		bad = ts_error; // || (! cc_ok);
     
 		afc = (packet[3] >> 4) & 3;
+		if(! (afc % 2))	//no payload in this TS packet
+		{
+			stream_skip(stream, buf_size-1+junk);
+			continue;
+		}
+		
 		if(afc > 1)
 		{
 			int c;
@@ -2637,12 +2643,6 @@
 				continue;
 		}
 		
-		if(! (afc % 2))	//no payload in this TS packet
-		{
-			stream_skip(stream, buf_size-1+junk);
-			continue;
-		}
-		
 		if(bad)
 		{
 			// logically this packet should be dropped, but if I do it