From f179c70bb5b97185997d68ec373f74ded576f836 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 21 Jul 2014 14:35:42 +1000 Subject: [PATCH] test: touchpads are too small for palm if we can't get the dimensions Signed-off-by: Peter Hutterer --- test/touchpad.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/touchpad.c b/test/touchpad.c index c1bdbd53..9b232bf4 100644 --- a/test/touchpad.c +++ b/test/touchpad.c @@ -1245,10 +1245,11 @@ static int touchpad_has_palm_detect_size(struct litest_device *dev) { double width, height; + int rc; - libinput_device_get_size(dev->libinput_device, &width, &height); + rc = libinput_device_get_size(dev->libinput_device, &width, &height); - return width >= 80; + return rc == 0 && width >= 80; } START_TEST(touchpad_palm_detect_at_edge) -- 2.34.1