diff options
| author | 2022-04-05 22:13:47 +0000 | |
|---|---|---|
| committer | 2022-04-05 22:13:47 +0000 | |
| commit | 7c8d637adfdbd11c75449e172fe155ee6e42790c (patch) | |
| tree | 65855dae2b788b4efb8f64ea61a05c48e930052b /libs/gui/SurfaceComposerClient.cpp | |
| parent | 36cf85e10ab0e1275349d68a220bd1f4f29de8e8 (diff) | |
| parent | 842a412840fbab2332a27d646a167177b110abf4 (diff) | |
Merge "DO NOT MERGE: SurfaceFlinger: Add Transaction#sanitize" into sc-qpr1-dev
Diffstat (limited to 'libs/gui/SurfaceComposerClient.cpp')
| -rw-r--r-- | libs/gui/SurfaceComposerClient.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libs/gui/SurfaceComposerClient.cpp b/libs/gui/SurfaceComposerClient.cpp index 6ffd25d227..3f1277ed57 100644 --- a/libs/gui/SurfaceComposerClient.cpp +++ b/libs/gui/SurfaceComposerClient.cpp @@ -527,6 +527,13 @@ SurfaceComposerClient::Transaction::Transaction(const Transaction& other) mListenerCallbacks = other.mListenerCallbacks; } +void SurfaceComposerClient::Transaction::sanitize() { + for (auto & [handle, composerState] : mComposerStates) { + composerState.state.sanitize(0 /* permissionMask */); + } + mInputWindowCommands.clear(); +} + std::unique_ptr<SurfaceComposerClient::Transaction> SurfaceComposerClient::Transaction::createFromParcel(const Parcel* parcel) { auto transaction = std::make_unique<Transaction>(); @@ -611,7 +618,6 @@ status_t SurfaceComposerClient::Transaction::readFromParcel(const Parcel* parcel if (composerState.read(*parcel) == BAD_VALUE) { return BAD_VALUE; } - composerStates[surfaceControlHandle] = composerState; } |