Ticket #2988: When an unknown key is pressed, it is interpreted as garbage.
commit77cfaf03cb501819417179b53ad25ec68ee41a52
authorDenys Vlasenko <vda.linux@googlemail.com>
Mon, 20 May 2013 12:34:21 +0000 (20 15:34 +0300)
committerSlava Zanko <slavazanko@gmail.com>
Thu, 23 May 2013 08:41:25 +0000 (23 11:41 +0300)
tree8214185c584c98bf9d8f2acf78aa67c88817c68a
parentf09b3198ec3d53119e8e8cc8d6668bf0f1973b03
Ticket #2988: When an unknown key is pressed, it is interpreted as garbage.

keyboard input: simplify code, no logic changes

This change slightly simplifies and rearranges the code
in get_key_code(), reduces indentation levels there,
adds a few comments. The logic remains the same.

This is a preparatory patch for subsequent changes.

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
lib/tty/key.c