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

Commit 57d7b5f3 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "SurfaceFlinger: Only allow update of InputWindowInfo with permission."

parents 64b61fa4 11ac2019
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -3961,8 +3961,12 @@ uint32_t SurfaceFlinger::setClientStateLocked(const ComposerState& composerState
        if (layer->setSidebandStream(s.sidebandStream)) flags |= eTraversalNeeded;
    }
    if (what & layer_state_t::eInputInfoChanged) {
        if (callingThreadHasUnscopedSurfaceFlingerAccess()) {
            layer->setInputInfo(s.inputInfo);
            flags |= eTraversalNeeded;
        } else {
            ALOGE("Attempt to update InputWindowInfo without permission ACCESS_SURFACE_FLINGER");
        }
    }
    std::vector<sp<CallbackHandle>> callbackHandles;
    if ((what & layer_state_t::eListenerCallbacksChanged) && (!s.listenerCallbacks.empty())) {