Skip to content

Commit 778e5c9

Browse files
committed
linux: Update struct input_event for __USE_TIME_BITS64
1 parent f6ef256 commit 778e5c9

File tree

1 file changed

+13
-1
lines changed
  • src/unix/linux_like/linux

1 file changed

+13
-1
lines changed

src/unix/linux_like/linux/mod.rs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,19 @@ s! {
324324
}
325325

326326
pub struct input_event {
327-
pub time: ::timeval,
327+
#[cfg(any(target_pointer_width = "64", not(linux_time_bits64)))]
328+
pub input_event_sec: ::time_t,
329+
#[cfg(all(target_pointer_width = "32", linux_time_bits64))]
330+
pub input_event_sec: ::c_ulong,
331+
332+
#[cfg(any(target_pointer_width = "64", not(linux_time_bits64)))]
333+
pub input_event_usec: ::suseconds_t,
334+
#[cfg(all(target_pointer_width = "32", linux_time_bits64))]
335+
pub input_event_usec: ::c_ulong,
336+
337+
#[cfg(target_arch = "sparc64")]
338+
_pad1: ::c_int,
339+
328340
pub type_: ::__u16,
329341
pub code: ::__u16,
330342
pub value: ::__s32,

0 commit comments

Comments
 (0)