Detaching from the tty makes little sense when asked to run on the same tty as we're started from. So automatically assume -keeptty in this case.
This is useful to do because when not running as root the server can only make various VT related ioctls when it does not detach from the tty. Signed-off-by: Hans de Goede <[email protected]> --- hw/xfree86/os-support/linux/lnx_init.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hw/xfree86/os-support/linux/lnx_init.c b/hw/xfree86/os-support/linux/lnx_init.c index 5f7d39b..52e629b 100644 --- a/hw/xfree86/os-support/linux/lnx_init.c +++ b/hw/xfree86/os-support/linux/lnx_init.c @@ -149,6 +149,10 @@ xf86OpenConsole(void) else activeVT = vts.v_active; + /* Don't detach from the tty when started on the active tty */ + if (xf86Info.vtno == activeVT) + KeepTty = TRUE; + if (!KeepTty) { pid_t ppid = getppid(); pid_t ppgid; -- 1.8.4.2 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
