diff options
author | Alexander Orzechowski <alex@ozal.ski> | 2023-10-03 01:51:07 -0400 |
---|---|---|
committer | Alexander Orzechowski <alex@ozal.ski> | 2023-10-03 01:51:07 -0400 |
commit | 1b0694b79481643cb456d03e1be50a1b4f6ca591 (patch) | |
tree | c693c5de3ee7ebd52873f6ec063118408f0bd28a /backend/libinput/events.c | |
parent | a09d6494397bdd28a3254d2e646212afb5a3049c (diff) |
treewide: Migrate from sizeof(struct) to sizeof(*pointer) where practical
Diffstat (limited to 'backend/libinput/events.c')
-rw-r--r-- | backend/libinput/events.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/backend/libinput/events.c b/backend/libinput/events.c index 85724c90..4726e32b 100644 --- a/backend/libinput/events.c +++ b/backend/libinput/events.c @@ -69,8 +69,7 @@ static void handle_device_added(struct wlr_libinput_backend *backend, const char *name = libinput_device_get_name(libinput_dev); wlr_log(WLR_DEBUG, "Adding %s [%d:%d]", name, vendor, product); - struct wlr_libinput_input_device *dev = - calloc(1, sizeof(struct wlr_libinput_input_device)); + struct wlr_libinput_input_device *dev = calloc(1, sizeof(*dev)); if (dev == NULL) { wlr_log_errno(WLR_ERROR, "failed to allocate wlr_libinput_input_device"); return; |