base-files: fix logic error in led default handling (patch from #19593)
authorFelix Fietkau <nbd@openwrt.org>
Sun, 3 May 2015 18:04:27 +0000 (18:04 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 3 May 2015 18:04:27 +0000 (18:04 +0000)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 45600

package/base-files/files/etc/init.d/led

index ba4dd6791d896f2059c2c500ef1a9f59b5379c39..1a57e8afd70a8a9ada0ff70a97e122a65a982e5b 100755 (executable)
@@ -35,7 +35,7 @@ load_led() {
        [ -e /sys/class/leds/${sysfs}/brightness ] && {
                echo "setting up led ${name}"
 
-               [ "$default" = 0 ] ||
+               [ "$default" = 0 ] &&
                        echo 0 >/sys/class/leds/${sysfs}/brightness
 
                echo $trigger > /sys/class/leds/${sysfs}/trigger 2> /dev/null