#!/bin/bash export TERM=linux . /etc/rc.conf . /etc/rc.d/functions . /usr/MythVantage/bin/install_functions.sh LOG=/tmp/remotes.log echo "`date` --- finish started" >> $LOG killall -9 lircd 2>/dev/null rm -f /var/run/lirc*.pid [ -e /etc/sv/remotes/.runtime ] || mkdir -p /etc/sv/remotes/.runtime touch /etc/sv/remotes/.runtime/`date +%s` numfiles=`/usr/bin/file_time_offset.py -s4 -d/etc/sv/remotes/.runtime ` if [ $numfiles -gt 3 ] then rm -f /etc/sv/remotes/.runtime/* 2>/dev/null sv stop remotes >> $LOG printhl " remotes is not able to start, disabling it" echo " remotes is not able to start, disabling it" >> $LOG fi echo "Enable in kernel remote driver" >> $LOG in_kernel_support "enable"