aboutsummaryrefslogtreecommitdiff
path: root/toys
diff options
context:
space:
mode:
Diffstat (limited to 'toys')
-rw-r--r--toys/pending/modprobe.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/toys/pending/modprobe.c b/toys/pending/modprobe.c
index f1c4338e..a3f5bb9e 100644
--- a/toys/pending/modprobe.c
+++ b/toys/pending/modprobe.c
@@ -238,7 +238,8 @@ static int config_action(struct dirtree *node)
break;
}
}
- if (!tk) continue;
+ // Every command requires at least one argument.
+ if (tcount < 2) continue;
// process the tokens[0] contains first word of config line.
if (!strcmp(tokens[0], "alias")) {
struct arg_list *temp;