Update idx and ev to the next event after the while check (which makes
sure that the next index is within bounds) to avoid a potential
access-past-end-of-array.
Revent is terminated from WA via a 'SIGINT', therefore this means
that in order for revent to receive the signal and deal with it
accordingly, revent always needs to be listening on STDIN regardless of
the 'wait_for_stdin' flag.
Fixed new gamemode not being set for compatibility mode.
Fixed input buffer not being flushed causing replay to fail.
Fixed infinte loop if revent recording did not end correctly.
Updated revent binaries.
- Added support for gamepad recording. This type of recording contains
only the events from a gamepad device (which is automatically
identified). The details of this devices are collected and stored as
part of the recording. On playback, uinput is used to create a virtual
gamepad and replay into it.
- A "mode" field has been added to the recording format to help
distinguish between the normal and gamepad recording types.
- A field for the total number of input events has been added before the
start of the event stream (after the device description).
- The structure of revent code has undergone a major overhaul to improve
maintainability and robustness.
- More detailed "info" command output.
- Updated Makefile to support debug/production builds.
Added two commands to WA to record and replay input events using revent.
As part of this also added the ability to get a device model from
android and linux device. This may need to be improved in the future.
The struct used to read events is being padded when built for 64
bit platforms. The padding has been made explicit in the struct, and
matching padding was added when writing the events during recording.
Then number of input event files was being written as a size_t but read
as an int by revent. These types have different sizes with 64bit GCC,
causing revent not being able to replay recorded files. This comint
updates revent to use size_t when both reading and writing.