tty: Fix mistyping of /dev/tty

/dev/tty stands for current terminal which we don't yet
implemented a support for.

This is a bugfix for upcoming stable version, the proper
support of /dev/tty is gonna be implemented separately.

Reported-by: Saied Kazemi <saied@google.com>
CC: Andrew Vagin <avagin@parallels.com>
CC: Pavel Emelyanov <xemul@parallels.com>
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
Cyrill Gorcunov 2015-02-20 00:11:38 +03:00 committed by Pavel Emelyanov
parent 2ecc25ef5e
commit bec5a023d1

View file

@ -31,7 +31,7 @@ static inline int tty_type(int major, int minor)
{
switch (major) {
case TTYAUX_MAJOR:
if (minor == 0 || minor == 2)
if (minor == 2)
return TTY_TYPE_PTM;
else if (minor == 1)
return TTY_TYPE_CONSOLE;