From 37f43662deb85d6409571f9e554945efc23571cf Mon Sep 17 00:00:00 2001 From: Chris Tallon Date: Sun, 31 Jul 2005 16:46:26 +0000 Subject: [PATCH] Patch from Dave Pickles for VDR 1.3 tv/radio channel detection --- mvpclient.c | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/mvpclient.c b/mvpclient.c index f5b36fd..a678a6b 100644 --- a/mvpclient.c +++ b/mvpclient.c @@ -360,17 +360,26 @@ void MVPClient::processGetChannelsList(unsigned char* data, int length) for (cChannel *channel = Channels.First(); channel; channel = Channels.Next(channel)) { - if (!channel->GroupSep()) +#if VDRVERSNUM < 10300 + if (!channel->GroupSep() && !channel->Ca()) +#else + if (!channel->GroupSep() && !channel->Ca(0)) +#endif { printf("name: '%s'\n", channel->Name()); + if (channel->Vpid()) type = 1; +#if VDRVERSNUM < 10300 + else type = 2; +#else + else if (channel->Apid(0)) type = 2; + else continue; +#endif + if (count > 49000) break; *(unsigned long*)&sendBuffer[count] = htonl(channel->Number()); count += 4; - if (channel->Vpid()) type = 1; - else type = 2; - *(unsigned long*)&sendBuffer[count] = htonl(type); count += 4; -- 2.39.5