SF: Prevent non-sync transactions from syncing
Clears the sync handle and frame number after registering a deferred
transaction to prevent other non-synchronized transactions from
erroneously getting marked as synchronized.
Also changes the application of pending states such that all valid
pending transactions are applied instead of breaking after the first
one.
Bug: 27061473
Change-Id: I98f0f26e9d9bb0d266563f209e94dfd776d8f8ea
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index d39075f..28e5e43 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -1000,8 +1000,9 @@
// Signal our end of the sync point and then dispose of it
mRemoteSyncPoints.front()->setTransactionApplied();
mRemoteSyncPoints.pop_front();
+ } else {
+ break;
}
- break;
} else {
popPendingState();
stateUpdateAvailable = true;
@@ -1240,6 +1241,8 @@
// request without any other state updates shouldn't actually induce a delay
mCurrentState.modified = true;
pushPendingState();
+ mCurrentState.handle = nullptr;
+ mCurrentState.frameNumber = 0;
mCurrentState.modified = false;
}