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

Commit 6b491b64 authored by Svetoslav's avatar Svetoslav Committed by Android (Google) Code Review
Browse files

Merge "Invalid accessibility state if UI test process crashes in a bad time." into lmp-dev

parents 86ef70eb 419036b5
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -2004,7 +2004,15 @@ public class AccessibilityManagerService extends IAccessibilityManager.Stub {
            } else {
                userState.mBindingServices.add(mComponentName);
                mService = userState.mUiAutomationServiceClient.asBinder();
                mMainHandler.post(new Runnable() {
                    @Override
                    public void run() {
                        // Simulate asynchronous connection since in onServiceConnected
                        // we may modify the state data in case of an error but bind is
                        // called while iterating over the data and bad things can happen.
                        onServiceConnected(mComponentName, mService);
                    }
                });
                userState.mUiAutomationService = this;
            }
            return false;