Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed bug 4656 - SDL_evdev.c uses Linux specific integer types
Jan Martin Mikkelsen

The file src/core/linux/SDL_evdev.c uses the Linux specific types __u32 and __s32. This breaks things on FreeBSD when building with evdev.
  • Loading branch information
slouken committed Jun 5, 2019
1 parent 723d014 commit 3e32946
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/core/linux/SDL_evdev.c
Expand Up @@ -556,8 +556,8 @@ SDL_EVDEV_sync_device(SDL_evdevlist_item *item)
*
* this is the structure we're trying to emulate
*/
__u32* mt_req_code;
__s32* mt_req_values;
uint32_t* mt_req_code;
int32_t* mt_req_values;
size_t mt_req_size;

/* TODO: sync devices other than touchscreen */
Expand All @@ -572,7 +572,7 @@ SDL_EVDEV_sync_device(SDL_evdevlist_item *item)
return;
}

mt_req_values = (__s32*)mt_req_code + 1;
mt_req_values = (int32_t*)mt_req_code + 1;

*mt_req_code = ABS_MT_TRACKING_ID;
ret = ioctl(item->fd, EVIOCGMTSLOTS(mt_req_size), mt_req_code);
Expand Down

0 comments on commit 3e32946

Please sign in to comment.