From: Olivier Brunel Date: Fri, 20 Sep 2013 20:18:29 +0000 (+0200) Subject: Only disable output on console during boot if needed X-Git-Tag: v209~1433 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=2f38577f3040eedebfe1ace05d5b5a779a588af1;ds=sidebyside Only disable output on console during boot if needed If there are no more jobs on console, no need/we shouldn't disable output. --- diff --git a/src/core/manager.c b/src/core/manager.c index 07ca4c92f..c99a022cd 100644 --- a/src/core/manager.c +++ b/src/core/manager.c @@ -1789,7 +1789,7 @@ static int process_event(Manager *m, struct epoll_event *ev) { } case WATCH_IDLE_PIPE: { - m->no_console_output = true; + m->no_console_output = m->n_on_console > 0; manager_unwatch_idle_pipe(m); close_idle_pipe(m); diff --git a/src/core/unit.c b/src/core/unit.c index 201329fc8..15e0a8202 100644 --- a/src/core/unit.c +++ b/src/core/unit.c @@ -1492,7 +1492,7 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, bool reload_su if (m->n_on_console == 0) /* unset no_console_output flag, since the console is free */ - m->no_console_output = 0; + m->no_console_output = false; } else m->n_on_console ++; }