mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Don't memset SEvent directly (#15359)
Fixes a compiler warning by manually zeroing the tag and the largest union member instead
This commit is contained in:
parent
8b85a62310
commit
5c5538685e
3 changed files with 7 additions and 8 deletions
|
@ -1581,7 +1581,6 @@ bool CIrrDeviceLinux::activateJoysticks(core::array<SJoystickInfo> &joystickInfo
|
|||
fcntl(info.fd, F_SETFL, O_NONBLOCK);
|
||||
#endif
|
||||
|
||||
(void)memset(&info.persistentData, 0, sizeof(info.persistentData));
|
||||
info.persistentData.EventType = irr::EET_JOYSTICK_INPUT_EVENT;
|
||||
info.persistentData.JoystickEvent.Joystick = ActiveJoysticks.size();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue