From e55c90b4c8fdf7a7cff2f0fbc109483d418021ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antti=20Sepp=C3=A4l=C3=A4?= Date: Thu, 27 Sep 2007 11:48:28 +0000 Subject: [PATCH] Perform filter inversion mimicing the original filter implementation. --- sectionfilter.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sectionfilter.c b/sectionfilter.c index 3f2267e..7e854fd 100644 --- a/sectionfilter.c +++ b/sectionfilter.c @@ -3,7 +3,7 @@ * * See the README file for copyright information and how to reach the author. * - * $Id: sectionfilter.c,v 1.5 2007/09/26 22:07:45 rahrenbe Exp $ + * $Id: sectionfilter.c,v 1.6 2007/09/27 11:48:28 ajhseppa Exp $ */ #include "sectionfilter.h" @@ -34,9 +34,14 @@ cIptvSectionFilter::cIptvSectionFilter(int Index, int devInd, SetPipeName(devInd); - filter_value[0] = !Tid; + filter_value[0] = Tid; filter_mask[0] = Mask; + // Invert the filter + for (int i = 0; i < DVB_DEMUX_MASK_MAX; ++i) { + filter_value[i] ^= 0xff; + } + uint8_t mask, mode, local_doneq = 0; for (int i = 0; i < DVB_DEMUX_MASK_MAX; i++) { mode = filter_mode[i];