Merge "init: expand_props on trigger"
This commit is contained in:
commit
4cc6e2e33f
1 changed files with 7 additions and 1 deletions
|
|
@ -591,7 +591,13 @@ int do_powerctl(int nargs, char **args)
|
||||||
|
|
||||||
int do_trigger(int nargs, char **args)
|
int do_trigger(int nargs, char **args)
|
||||||
{
|
{
|
||||||
action_for_each_trigger(args[1], action_add_queue_tail);
|
char prop_val[PROP_VALUE_MAX];
|
||||||
|
int res = expand_props(prop_val, args[1], sizeof(prop_val));
|
||||||
|
if (res) {
|
||||||
|
ERROR("trigger: cannot expand '%s'\n", args[1]);
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
action_for_each_trigger(prop_val, action_add_queue_tail);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue