Ensure channel receives a consistent touch stream
Add an event verifier to check the touch streams that are being sent to
the input channel.
If a stream is inconsistent, crash.
For now, only touch streams are being verified. Disable the feature
while the bugs are being fixed.
Bug: 267082966
Test: m inputflinger_tests && $ANDROID_HOST_OUT/nativetest64/inputflinger_tests/inputflinger_tests
Merged-In: Ibb8ab70b0019789c1a17dae0077be6b23d3d9139
Change-Id: Ibb8ab70b0019789c1a17dae0077be6b23d3d9139
(cherry picked from commit f06b672b3e433121037398c7255098ed0130c649)
diff --git a/include/input/InputTransport.h b/include/input/InputTransport.h
index 1c52792..a1be542 100644
--- a/include/input/InputTransport.h
+++ b/include/input/InputTransport.h
@@ -38,6 +38,7 @@
#include <binder/IBinder.h>
#include <binder/Parcelable.h>
#include <input/Input.h>
+#include <input/InputVerifier.h>
#include <sys/stat.h>
#include <ui/Transform.h>
#include <utils/BitSet.h>
@@ -444,6 +445,7 @@
private:
std::shared_ptr<InputChannel> mChannel;
+ InputVerifier mInputVerifier;
};
/*