summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2016-07-13 07:54:07 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2016-07-13 08:33:30 +1000
commit53baf3d17f0bd6f861115157dbf82cb4e87490a3 (patch)
treec458c12c1cc4445d0add358f00422ffb72f6a938 /src
parent11586b7f34ca04bffca26c41f0fb28a6c7a74999 (diff)
tablet: catch potential segfault if the filter fails to allocate
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'src')
-rw-r--r--src/evdev-tablet.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/evdev-tablet.c b/src/evdev-tablet.c
index 940a1e06..d751f2ff 100644
--- a/src/evdev-tablet.c
+++ b/src/evdev-tablet.c
@@ -1599,6 +1599,8 @@ tablet_init_accel(struct tablet_dispatch *tablet, struct evdev_device *device)
filter = create_pointer_accelerator_filter_tablet(x->resolution,
y->resolution);
+ if (!filter)
+ return -1;
rc = evdev_device_init_pointer_acceleration(device, filter);
if (rc != 0)