diff options
author | Daniel Stone <daniel@fooishbar.org> | 2012-12-29 03:24:52 +0000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2013-01-02 11:35:04 +1000 |
commit | ce7565ea6683f594f1f2ab5769bf60b1337d70bd (patch) | |
tree | 7c315a17fc1518572b0110ef5808b60ac55e7150 /src/eventcomm.c | |
parent | a5ac54f60af96b9b862425ccd8b6c7afaa4937e4 (diff) |
Free mtdev device as well as closing it
mtdev_close_delete() is to mtdev_new_open() as mtdev_close() is to
mtdev_open(). So, since we're using mtdev_new_open(), we need to use
mtdev_close_delete() instead of just mtdev_close() to actually free
everything.
Fixes an eventual failure to open the touchpad device after a lot of
suspend/resume cycles.
[whot: amended to mtdev_close_delete in evdev_query_touch]
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'src/eventcomm.c')
-rw-r--r-- | src/eventcomm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/eventcomm.c b/src/eventcomm.c index b1d5460..6f4d2a5 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -122,7 +122,7 @@ UninitializeTouch(InputInfoPtr pInfo) proto_data->last_mt_vals = NULL; } - mtdev_close(proto_data->mtdev); + mtdev_close_delete(proto_data->mtdev); proto_data->mtdev = NULL; proto_data->num_touches = 0; } @@ -852,7 +852,7 @@ event_query_touch(InputInfoPtr pInfo) } out: - mtdev_close(mtdev); + mtdev_close_delete(mtdev); } /** |