From 3271defd328ad2c33e88de0bcf0600f1b2c8f1ec Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 30 Nov 2021 10:36:44 +1000 Subject: Pass the context to two helper functions In both cases we'll use that context in a follow-up patch to hook into the logging functions. Signed-off-by: Peter Hutterer --- test/wacom-tests.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'test') diff --git a/test/wacom-tests.c b/test/wacom-tests.c index 6642796..0fbbe71 100644 --- a/test/wacom-tests.c +++ b/test/wacom-tests.c @@ -510,16 +510,17 @@ test_tilt_to_rotation(void) static void test_mod_buttons(void) { + WacomCommonRec common = {0}; int i; for (i = 0; i < sizeof(int) * 8; i++) { - int buttons = mod_buttons(0, i, 1); + int buttons = mod_buttons(&common, 0, i, 1); assert(buttons == (1 << i)); - buttons = mod_buttons(0, i, 0); + buttons = mod_buttons(&common, 0, i, 0); assert(buttons == 0); } - assert(mod_buttons(0, sizeof(int) * 8, 1) == 0); + assert(mod_buttons(&common, 0, sizeof(int) * 8, 1) == 0); } static void test_set_type(void) -- cgit v1.2.1