Skip to content

Commit

Permalink
Fixed the issue that tty information would not be written to utmp whe…
Browse files Browse the repository at this point in the history
…n logging in to a Wayland session.
  • Loading branch information
liuyuanpeng176 authored and robert-ancell committed Jan 16, 2024
1 parent f772b5e commit 290a74c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/wayland-session.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ wayland_session_connect_session (DisplayServer *display_server, Session *session
{
g_autofree gchar *value = g_strdup_printf ("%d", priv->vt);
session_set_env (session, "XDG_VTNR", value);

g_autofree gchar *tty_text = NULL;
tty_text = g_strdup_printf("/dev/tty/%d",priv->vt);
session_set_tty(session,tty_text);
}
}

Expand Down

0 comments on commit 290a74c

Please sign in to comment.