Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4b057038 authored by Siarhei Vishniakou's avatar Siarhei Vishniakou
Browse files

Initialize pointerCapture

Currently, pointerCapture variable is not initialized, so it will be set
to whatever is currently occupying that address.

This causes flakiness of the input native tests,
because in this test case, FakeInputReaderPolicy does not do any special
initialization for InputReaderConfiguration.

Bug: 117116942
Test: asan-built inputflinger tests
Change-Id: Id9a6b2f57bf3722e9d92ba1408468cf3bdf721b2
parent 0a1e8185
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -268,7 +268,7 @@ struct InputReaderConfiguration {
            pointerGestureSwipeMaxWidthRatio(0.25f),
            pointerGestureMovementSpeedRatio(0.8f),
            pointerGestureZoomSpeedRatio(0.3f),
            showTouches(false) { }
            showTouches(false), pointerCapture(false) { }

    std::optional<DisplayViewport> getDisplayViewportByType(ViewportType type) const;
    std::optional<DisplayViewport> getDisplayViewportByUniqueId(const std::string& uniqueDisplayId)