mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-10-28 03:25:27 +03:00
util: use open_terminal() in chvt() too
This commit is contained in:
parent
ec6370a22d
commit
74bc3bdc20
@ -2141,7 +2141,7 @@ bool fstype_is_network(const char *fstype) {
|
||||
int chvt(int vt) {
|
||||
int fd, r = 0;
|
||||
|
||||
if ((fd = open("/dev/tty0", O_RDWR|O_NOCTTY|O_CLOEXEC)) < 0)
|
||||
if ((fd = open_terminal("/dev/tty0", O_RDWR|O_NOCTTY|O_CLOEXEC)) < 0)
|
||||
return -errno;
|
||||
|
||||
if (vt < 0) {
|
||||
|
Loading…
Reference in New Issue
Block a user