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

Commit a35993b8 authored by Bin Zhai's avatar Bin Zhai Committed by Evan Rosky
Browse files

Create new SurfaceControl.Transaction when old closed

The SurfaceControl.Transaction will be closed after use. If TransactionCommittedListener can not be called in time, sytem_server will crash when merge Transaction.

Bug: 281823781
Test: run monkey test pass

Change-Id: I68d9809aaebc3a217b0c5287323c65c4f9fd05b9
parent 8020b8b6
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -248,7 +248,10 @@ class BLASTSyncEngine {
                    Slog.e(TAG, "WM sent Transaction to organized, but never received" +
                           " commit callback. Application ANR likely to follow.");
                    Trace.traceEnd(TRACE_TAG_WINDOW_MANAGER);
                    onCommitted(merged);
                    synchronized (mWm.mGlobalLock) {
                        onCommitted(merged.mNativeObject != 0
                                ? merged : mWm.mTransactionFactory.get());
                    }
                }
            };
            CommitCallback callback = new CommitCallback();