uml: line.c: avoid NULL pointer dereference

Assign tty only if line is not NULL.

[[email protected]: simplification]
Signed-off-by: Alexander Beregalov <[email protected]>
Cc: Jeff Dike <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
1 file changed