summaryrefslogtreecommitdiffstats
path: root/inittab.c
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2013-11-14 13:41:13 +0100
committerJohn Crispin <blogic@openwrt.org>2013-11-15 17:05:20 +0100
commit916f95cb58604038695347ee41a430d8ca1f0556 (patch)
tree5dbb52a6adaf28c6c6989ea37e6975aa52075160 /inittab.c
parentf9d31edb8938341b9217ee4c14eb58111414eb97 (diff)
downloadunitd-916f95cb58604038695347ee41a430d8ca1f0556.tar
unitd-916f95cb58604038695347ee41a430d8ca1f0556.zip
debloat and reorganize code
split app into procd and init binaries remove log support, this is an external service now Signed-off-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'inittab.c')
-rw-r--r--inittab.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/inittab.c b/inittab.c
index d73e0b8..e935ece 100644
--- a/inittab.c
+++ b/inittab.c
@@ -72,7 +72,7 @@ static void fork_worker(struct init_action *a)
}
if (a->proc.pid > 0) {
- DEBUG(2, "Launched new %s action, pid=%d\n",
+ DEBUG(4, "Launched new %s action, pid=%d\n",
a->handler->name,
(int) a->proc.pid);
uloop_process_add(&a->proc);
@@ -83,7 +83,7 @@ static void child_exit(struct uloop_process *proc, int ret)
{
struct init_action *a = container_of(proc, struct init_action, proc);
- DEBUG(2, "pid:%d\n", proc->pid);
+ DEBUG(4, "pid:%d\n", proc->pid);
uloop_timeout_set(&a->tout, a->respawn);
}
@@ -116,7 +116,7 @@ static void askfirst(struct init_action *a)
i = stat(a->id, &s);
chdir("/");
if (i || (console && !strcmp(console, a->id))) {
- DEBUG(2, "Skipping %s\n", a->id);
+ DEBUG(4, "Skipping %s\n", a->id);
return;
}
@@ -156,7 +156,7 @@ static void askconsole(struct init_action *a)
i = stat(tty, &s);
chdir("/");
if (i) {
- DEBUG(2, "skipping %s\n", tty);
+ DEBUG(4, "skipping %s\n", tty);
goto err_out;
}
console = strdup(tty);
@@ -265,7 +265,7 @@ void procd_inittab(void)
if (regexec(&pat_inittab, line, 5, matches, 0))
continue;
- DEBUG(2, "Parsing inittab - %s", line);
+ DEBUG(4, "Parsing inittab - %s", line);
for (i = TAG_ID; i <= TAG_PROCESS; i++) {
line[matches[i].rm_eo] = '\0';