diff options
author | 2016-07-12 22:02:53 +0000 | |
---|---|---|
committer | 2016-07-12 22:02:53 +0000 | |
commit | a94ea0c4b8634fcbf106233540088738c70c0abe (patch) | |
tree | c1db0268974e170d74be3e547c096c54f2423fb8 | |
parent | The only valid flag for unmount(2) is MNT_FORCE, ignore any others. (diff) | |
download | wireguard-openbsd-a94ea0c4b8634fcbf106233540088738c70c0abe.tar.xz wireguard-openbsd-a94ea0c4b8634fcbf106233540088738c70c0abe.zip |
Reset the mt state completely in wsmouse_mt_init.
ok kettenis@
-rw-r--r-- | sys/dev/wscons/wsmouse.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sys/dev/wscons/wsmouse.c b/sys/dev/wscons/wsmouse.c index b5ade6d649a..1d59fca1f9d 100644 --- a/sys/dev/wscons/wsmouse.c +++ b/sys/dev/wscons/wsmouse.c @@ -1,4 +1,4 @@ -/* $OpenBSD: wsmouse.c,v 1.31 2016/07/05 19:33:14 bru Exp $ */ +/* $OpenBSD: wsmouse.c,v 1.32 2016/07/12 22:02:53 bru Exp $ */ /* $NetBSD: wsmouse.c,v 1.35 2005/02/27 00:27:52 perry Exp $ */ /* @@ -1266,11 +1266,8 @@ wsmouse_mt_init(struct device *sc, int num_slots, int tracking) &((struct wsmouse_softc *) sc)->input; int n, size; - if (num_slots == input->mt.num_slots - && (!tracking == ((input->flags & MT_TRACKING) == 0))) - return (0); - free_mt_slots(input); + memset(&input->mt, 0, sizeof(struct mt_state)); if (tracking) input->flags |= MT_TRACKING; |