mirror of
https://github.com/troglobit/finit.git
synced 2026-10-02 05:52:48 +07:00
initctl: show, use '-' for runlevels service is not member of
This patch adds a '-' for each runlevel a service/task is not part of. The resulting listings are easier to read and also makes it clearer to the user what happens when changing runlevels. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
@@ -445,6 +445,8 @@ char *runlevel_string(int runlevel, int levels)
|
||||
|
||||
if (runlevel == i)
|
||||
pos = strlcat(lvl, "\e[0m", sizeof(lvl));
|
||||
} else {
|
||||
lvl[pos++] = '-';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user