From bd99ed281a1d552f1d4a8aa3baee89d06e6c72c8 Mon Sep 17 00:00:00 2001 From: Christian Wieninger Date: Mon, 25 Aug 2008 19:04:30 +0200 Subject: avoid switching if current channel already matches the switch timers one --- switchtimer_thread.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/switchtimer_thread.c b/switchtimer_thread.c index 7f6388f..2988498 100644 --- a/switchtimer_thread.c +++ b/switchtimer_thread.c @@ -97,7 +97,8 @@ void cSwitchTimerThread::Action(void) { LogFile.Log(1,"switching to channel %d", channel->Number()); cString cmd = cString::sprintf("CHAN %d", channel->Number()); - SendViaSVDRP(cmd); + if (cDevice::CurrentChannel() != channel->Number()) + SendViaSVDRP(cmd); if (switchTimer->unmute && cDevice::PrimaryDevice()->IsMute()) cDevice::PrimaryDevice()->ToggleMute(); -- cgit v1.2.3