From 108ebe83017e737800664a26a6495e0025326beb Mon Sep 17 00:00:00 2001 From: TangoCash Date: Fri, 9 Sep 2022 22:43:15 +0200 Subject: [PATCH] send ecm pids in stream only in raw mode --- src/driver/streamts.cpp | 6 +++--- src/driver/streamts.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/driver/streamts.cpp b/src/driver/streamts.cpp index 8f3beaa85..c50cbf9b0 100644 --- a/src/driver/streamts.cpp +++ b/src/driver/streamts.cpp @@ -492,12 +492,12 @@ bool CStreamManager::Parse(int fd, stream_pids_t &pids, t_channel_id &chid, CFro return false; } - AddPids(fd, channel, pids); + AddPids(fd, channel, pids, send_raw); return !pids.empty(); } -void CStreamManager::AddPids(int fd, CZapitChannel *channel, stream_pids_t &pids) +void CStreamManager::AddPids(int fd, CZapitChannel *channel, stream_pids_t &pids, bool send_raw) { if (pids.empty()) { printf("CStreamManager::AddPids: searching channel %" PRIx64 " pids\n", channel->getChannelID()); @@ -511,7 +511,7 @@ void CStreamManager::AddPids(int fd, CZapitChannel *channel, stream_pids_t &pids pids.insert(channel->getAudioChannel(i)->pid); printf("CStreamManager::AddPids: apid 0x%04x \n", channel->getAudioChannel(i)->pid); } - if (!channel->capids.empty()) + if (!channel->capids.empty() && send_raw) { for(casys_pids_iterator_t it = channel->capids.begin(); it != channel->capids.end(); ++it) { diff --git a/src/driver/streamts.h b/src/driver/streamts.h index 1b64023b6..b28bae408 100644 --- a/src/driver/streamts.h +++ b/src/driver/streamts.h @@ -122,7 +122,7 @@ class CStreamManager : public OpenThreads::Thread bool Listen(); bool Parse(int fd, stream_pids_t &pids, t_channel_id &chid, CFrontend * &frontend, bool &send_raw); - void AddPids(int fd, CZapitChannel * channel, stream_pids_t &pids); + void AddPids(int fd, CZapitChannel * channel, stream_pids_t &pids, bool send_raw); void CheckStandby(bool enter); CFrontend * FindFrontend(CZapitChannel * channel); bool StopAll();