vt: fix old keyboard release in CONS_SETKBD
On the first switch we previously released the newly allocated keyboard instead of the old one. Keyboard state was very confused afterwards for further keyboard switches. Submitted by: bde
This commit is contained in:
parent
956381ee95
commit
1951ee312a
@ -2359,6 +2359,7 @@ vtterm_ioctl(struct terminal *tm, u_long cmd, caddr_t data,
|
||||
(void *)vd, vt_kbdevent, vd);
|
||||
if (i >= 0) {
|
||||
if (vd->vd_keyboard != -1) {
|
||||
kbd = kbd_get_keyboard(vd->vd_keyboard);
|
||||
vt_save_kbd_state(vd->vd_curwindow, kbd);
|
||||
kbd_release(kbd, (void *)vd);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user