summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHristo Mitrev <hr.mitrev@gmail.com>2022-10-17 15:26:37 +0300
committerWez Furlong <wez@wezfurlong.org>2022-10-17 07:30:15 -0700
commit6ac2a1c4830f965b834c09e945fc289aa4e40ab3 (patch)
tree3c0cc0d1e2f185e5c9d70c249ce9e7a03f17dca9
parent5a280cba5830d830f800613caf3a23f0a110271e (diff)
Fix build on i386 architecture
Signed-off-by: Hristo Mitrev <hr.mitrev@gmail.com>
-rw-r--r--Cargo.toml1
-rw-r--r--src/remapper.rs2
2 files changed, 2 insertions, 1 deletions
diff --git a/Cargo.toml b/Cargo.toml
index 27e27a5..fd7bc25 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -13,3 +13,4 @@ structopt = "0.3"
serde = { version="1.0", features=["derive"]}
thiserror = "1.0"
toml = "0.5"
+libc = "0.2"
diff --git a/src/remapper.rs b/src/remapper.rs
index b33c0e2..0e90697 100644
--- a/src/remapper.rs
+++ b/src/remapper.rs
@@ -35,7 +35,7 @@ impl KeyEventType {
}
fn timeval_diff(newer: &TimeVal, older: &TimeVal) -> Duration {
- const MICROS_PER_SECOND: i64 = 1000000;
+ const MICROS_PER_SECOND: libc::time_t = 1000000;
let secs = newer.tv_sec - older.tv_sec;
let usecs = newer.tv_usec - older.tv_usec;