Commit 69d5b1eb authored by Markus Gothe's avatar Markus Gothe 👌
Browse files

If LEDs are not in 'normal' mode we don't want a third party to interfere with them.

parent 7e0e8dc4
Pipeline #1851 passed with stage
in 22 seconds
......@@ -475,6 +475,11 @@ static int led_set_method(struct ubus_context *ubus_ctx, struct ubus_object *obj
int number;
char *fn_name = strchr(obj->name, '.') + 1;
if (global_state != LEDS_NORMAL) {
DBG(1,"Not in normal mode");
return 0;
blobmsg_parse(led_policy, ARRAY_SIZE(led_policy), tb, blob_data(msg), blob_len(msg));
if (tb[LED_STATE]) {
state = blobmsg_data(tb[LED_STATE]);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment