[openwrt/openwrt] base-files: LED/gpio: Ensure inverted is read as a boolean
LEDE Commits
lede-commits at lists.infradead.org
Sat Aug 6 10:59:03 PDT 2022
hauke pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/b8f27251c9f755f7219391daa0e15318a12972a3
commit b8f27251c9f755f7219391daa0e15318a12972a3
Author: Olliver Schinagl <oliver at schinagl.nl>
AuthorDate: Sun Jul 31 10:19:09 2022 +0200
base-files: LED/gpio: Ensure inverted is read as a boolean
The sysfs interface for the GPIO takes a boolean value. Ensure we get
one from uci.
Signed-off-by: Olliver Schinagl <oliver at schinagl.nl>
---
package/base-files/files/etc/init.d/led | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package/base-files/files/etc/init.d/led b/package/base-files/files/etc/init.d/led
index 51cb8b5178..732ac59a84 100755
--- a/package/base-files/files/etc/init.d/led
+++ b/package/base-files/files/etc/init.d/led
@@ -29,7 +29,7 @@ load_led() {
config_get delay $1 delay "150"
config_get message $1 message ""
config_get gpio $1 gpio "0"
- config_get inverted $1 inverted "0"
+ config_get_bool inverted $1 inverted "0"
# execute application led trigger
[ -f "/usr/libexec/led-trigger/${trigger}" ] && {
More information about the lede-commits
mailing list