From: John Crispin Date: Wed, 27 Aug 2008 20:33:13 +0000 (+0000) Subject: fixes broken if-then in led init script X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=12df593510d877a11d0325c0a6dad2c697d5fc70;p=openwrt%2Fstaging%2Frobimarko.git fixes broken if-then in led init script SVN-Revision: 12411 --- diff --git a/package/base-files/files/etc/init.d/led b/package/base-files/files/etc/init.d/led index cf7bf4203d..1f05d724a2 100755 --- a/package/base-files/files/etc/init.d/led +++ b/package/base-files/files/etc/init.d/led @@ -26,8 +26,9 @@ load_led() { logger "setting up led : $name" [ -n "$default" ] && { [ $default -eq 1 ] && - echo 1 >/sys/class/leds/${sysfs}/brightness \ - || echo 0 >/sys/class/leds/${sysfs}/brightness + echo 1 >/sys/class/leds/${sysfs}/brightness + [ $default -eq 1 ] || + echo 0 >/sys/class/leds/${sysfs}/brightness } [ -z "$trigger" ] && trigger=none echo $trigger > /sys/class/leds/${sysfs}/trigger