From: Grazvydas Ignotas Date: Fri, 5 Aug 2011 15:31:33 +0000 (+0300) Subject: pandora-state: check for state file before using it X-Git-Tag: sz_beta3~100 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=openpandora.oe.git;a=commitdiff_plain;h=c7ad3bef106f84bcb3921c28bce3f8ed73e59066;ds=sidebyside pandora-state: check for state file before using it Reported-by: Klaus Brinkmann --- diff --git a/recipes/pandora-system/pandora-state/rc.pandora-state b/recipes/pandora-system/pandora-state/rc.pandora-state index fd058ff..a1f6d46 100644 --- a/recipes/pandora-system/pandora-state/rc.pandora-state +++ b/recipes/pandora-system/pandora-state/rc.pandora-state @@ -38,8 +38,10 @@ d_start() { cat /etc/pandora/conf/dirty_expire_centisecs > /proc/sys/vm/dirty_expire_centisecs cat /etc/pandora/conf/brightness.state > /sys/devices/platform/twl4030-pwm0-bl/backlight/twl4030-pwm0-bl/brightness cat /etc/pandora/conf/gamma.state > /sys/devices/platform/omap2_mcspi.1/spi1.1/gamma - filter=$(cat /etc/pandora/conf/filter.state) - /usr/pandora/scripts/op_videofir.sh $filter + if [ -f /etc/pandora/conf/filter.state ]; then + filter=$(cat /etc/pandora/conf/filter.state) + /usr/pandora/scripts/op_videofir.sh $filter + fi cpuspeed="$(cat /etc/pandora/conf/cpu.conf | grep default | awk -F\: '{print $2}')" oppmax="$(cat /etc/pandora/conf/cpu.conf | grep opp | awk -F\: '{print $2}')" echo $oppmax > /proc/pandora/cpu_opp_max