Systemd/src/vconsole
Michal Soltys 1142bed25e vconsole: search for usable source console (#6180)
When vconsole-setup is called without arguments, search for a usable
console instead of using /dev/tty0.

/dev/tty0 — pointing to the current active console — it not necessarily
usable and in such case vconsole-setup would exit with failure. In particular
when systemd-vconsole-setup.service was restarted from within an X
session, it always failed.

If the function searching for a usable source terminal fails, the first
encountered error is returned to the caller.

Closes #5367.

Additional changes:

- true/false functions with 'is_ prefix are renamed to functions with
  'verify_vc_' prefix and return 0 on success and negative error on
  failure
- O_NOCTTY flag is used when opening terminals
2017-07-03 12:38:13 -04:00
..
.gitignore vconsole: don't hard-code systemd-vconsole-setup binary path 2014-12-04 00:05:04 +01:00
90-vconsole.rules.in vconsole: skip unnecessary udev call for dummy device 2016-10-21 16:30:27 +02:00
Makefile build-sys: add stub makefiles to subdirs 2012-01-05 16:29:21 +01:00
meson.build meson: use booleans for conf.set and drop unecessary conditionals 2017-05-02 16:29:11 -04:00
vconsole-setup.c vconsole: search for usable source console (#6180) 2017-07-03 12:38:13 -04:00