1
0
mirror of https://github.com/rofafor/vdr-plugin-iptv.git synced 2023-10-10 11:37:03 +00:00

Move code around.

This commit is contained in:
Antti Seppälä
2007-10-05 20:01:24 +00:00
parent 978fb7aa0f
commit 827b1bbc2e
5 changed files with 38 additions and 28 deletions

View File

@@ -3,7 +3,7 @@
*
* See the README file for copyright information and how to reach the author.
*
* $Id: sectionfilter.c,v 1.7 2007/10/05 19:00:44 ajhseppa Exp $
* $Id: sectionfilter.c,v 1.8 2007/10/05 20:01:24 ajhseppa Exp $
*/
#include "sectionfilter.h"
@@ -11,26 +11,6 @@
#define IPTV_FILTER_FILENAME "/tmp/vdr-iptv%d.filter%d"
uint16_t ts_pid(const uint8_t *buf)
{
return ((buf[1] & 0x1f) << 8) + buf[2];
}
uint8_t payload(const uint8_t *tsp)
{
if (!(tsp[3] & 0x10)) // no payload?
return 0;
if (tsp[3] & 0x20) { // adaptation field?
if (tsp[4] > 183) // corrupted data?
return 0;
else
return 184 - 1 - tsp[4];
}
return 184;
}
cIptvSectionFilter::cIptvSectionFilter(int Index, int devInd,
u_short Pid, u_char Tid, u_char Mask)
: pusi_seen(0),