Fix reMarkable crash bug v2022.05: event overwrite with new time module (#9121)

The change from timeval to time completely broke reMarkable.
frontend/device/remarkable/device.lua was using TimeVal:now() to manually overwrite event time values, as noted in the code comments.
Input:handleTouchEv is expecting those event time values to be timevals, not integer times.
So as soon as the user touches the screen, crash.
This commit is contained in:
Glen Sawyer
2022-05-22 00:01:24 -06:00
committed by GitHub
parent 2b3043796c
commit cb95dcd4c9

View File

@@ -95,7 +95,11 @@ function Remarkable2:adjustTouchEvent(ev, by)
-- Inject CLOCK_MONOTONIC timestamps at the end of every input frame in order to have consistent gesture detection across input devices.
-- c.f., #7536
if ev.type == C.EV_SYN and ev.code == C.SYN_REPORT then
ev.time = time.now()
local sec, usec = time.split_s_us(time.now())
ev.time = {
sec = sec,
usec = usec
}
end
end