diff options
| author | Kimplul <kimi.h.kuparinen@gmail.com> | 2022-03-12 20:53:39 +0200 |
|---|---|---|
| committer | Kimplul <kimi.h.kuparinen@gmail.com> | 2022-03-12 20:53:39 +0200 |
| commit | 9b6810ba6e1bd2553e205eb6719844253d5ce051 (patch) | |
| tree | c089f895afd8805336cdd1a04160d3558db9f83b /hid-tmff2.h | |
| parent | 60e90e0a96039c58968de551aadca0fab490d35d (diff) | |
| download | hid-tmff2-9b6810ba6e1bd2553e205eb6719844253d5ce051.tar.gz hid-tmff2-9b6810ba6e1bd2553e205eb6719844253d5ce051.zip | |
fix crashes
Diffstat (limited to 'hid-tmff2.h')
| -rw-r--r-- | hid-tmff2.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/hid-tmff2.h b/hid-tmff2.h index bdde1a7..b2a46c9 100644 --- a/hid-tmff2.h +++ b/hid-tmff2.h @@ -60,7 +60,7 @@ struct tmff2_device_entry { int (*update_effect)(void *data, struct tmff2_effect_state *state); int (*stop_effect)(void *data, struct tmff2_effect_state *state); - int (*wheel_init)(void *data); + int (*wheel_init)(struct tmff2_device_entry *tmff2); int (*wheel_destroy)(void *data); /* optional callbacks */ @@ -71,6 +71,8 @@ struct tmff2_device_entry { int (*switch_mode)(void *data, uint16_t mode); int (*set_autocenter)(void *data, uint16_t autocenter); __u8 *(*wheel_fixup)(struct hid_device *hdev, __u8 *rdesc, unsigned int *rsize); + + /* void pointers are dangerous, I know, but in this case likely the best option... */ }; #endif /* _HID_TMFF2 */ |
