summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/ts.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/ts.c b/tools/ts.c
index 0f5c835c..0122e2e9 100644
--- a/tools/ts.c
+++ b/tools/ts.c
@@ -4,7 +4,7 @@
* See the main source file 'xineliboutput.c' for copyright information and
* how to reach the author.
*
- * $Id: ts.c,v 1.29 2011-11-13 09:45:01 phintuka Exp $
+ * $Id: ts.c,v 1.30 2012-12-31 16:44:27 phintuka Exp $
*
*/
@@ -321,6 +321,11 @@ int ts_parse_pmt (pmt_data_t *pmt, uint program_no, const uint8_t *pkt)
}
}
+ if (!pmt->pmt) {
+ LOGMSG("parse_pmt: dropping PMT packet without PUSI");
+ return 0;
+ }
+
if (!pusi) {
section_length = (pmt->pmt[1] << 8 | pmt->pmt[2]) & 0x03ff;
version_number = (pkt[10] >> 1) & 0x1f;