summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2014-09-13 03:15:21 +0200
committerJohn Crispin <blogic@openwrt.org>2014-09-13 03:17:24 +0200
commitc1a558f7d0c1e6c1ffa5a47d557a7b45205eef1d (patch)
treea951817cbfb1322f68a725ef4429566199ff748d
parent81c9904b57d3aed01ca6d4ad027d6fc29f7fbc93 (diff)
downloadunitd-c1a558f7d0c1e6c1ffa5a47d557a7b45205eef1d.tar
unitd-c1a558f7d0c1e6c1ffa5a47d557a7b45205eef1d.zip
fix a copy/paste bug leading to a bad loop limitation
https://dev.openwrt.org/ticket/17864 Signed-off-by: John Crispin <blogic@openwrt.org>
-rw-r--r--inittab.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/inittab.c b/inittab.c
index 677ec47..c8540b1 100644
--- a/inittab.c
+++ b/inittab.c
@@ -279,7 +279,7 @@ void procd_inittab(void)
};
tok = strtok(tags[TAG_PROCESS], " ");
- for (i = 0; i < (MAX_ARGS - i - 1) && tok; i++) {
+ for (i = 0; i < (MAX_ARGS - 1) && tok; i++) {
a->argv[i] = tok;
tok = strtok(NULL, " ");
}