]> git.ipfire.org Git - thirdparty/systemd.git/commit
vconsole-setup: handle the case where the vc is in KD_GRAPHICS mode more gracefully
authorFranck Bui <fbui@suse.com>
Thu, 14 Dec 2023 11:07:46 +0000 (12:07 +0100)
committerFranck Bui <fbui@suse.com>
Mon, 18 Dec 2023 14:48:53 +0000 (15:48 +0100)
commit58161db61ba933f1e3e7395d1f50fe0213bb82f2
tree34cb5f76a04c5d825468257c1730df47212d8885
parent68f74b0af2c6455abfa31f29bd84517bc20c729b
vconsole-setup: handle the case where the vc is in KD_GRAPHICS mode more gracefully

Regardless of whether a vc path is passed, the behavior of
systemd-vconsole-setup wasn't ideal when either the passed vc or /dev/tty1 was
in graphics mode.

When a vc in graphics mode was passed, no message was emitted despite the fact
that the font settings couldn't be applied. The previous code might have
assumed that setfont(8) would throw a warning but that's not case.

When no argument was passed, systemd-vconsole-setup was supposed to
automatically select a valid tty, init it and copy the font setting to the
remaining ttys. However if the selected virtual console was in KD_GRAPHICS mode
the initialization of the font failed not only for the selected source vc but
for all of them.
src/vconsole/vconsole-setup.c