seat: Avoid holding a tty fd

The kernel Secure Attention Key killer, triggered by SysRq+k, kills all
processes that hold an fd referencing the tty.

To avoid its attention, we stop storing the fd for the currently active
VT in seat state. This has the added benefit of simplifying state a bit.
This commit is contained in:
Kenny Levinsen 2021-04-23 00:17:19 +02:00
parent 15b0972bd3
commit df3f307b8e
2 changed files with 16 additions and 36 deletions

View file

@ -33,7 +33,6 @@ struct seat {
struct client *next_client;
bool vt_bound;
int cur_ttyfd;
int cur_vt;
int session_cnt;
};