Merge "Fix the problem that AccessibilityNodeInfo maybe null and cause a crash." am: 27c5bed4fa am: 5404eb28a7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2606576 Change-Id: Ibb1da80b8002a19c9adf1e4c8066a1de4c44b299 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -9137,8 +9137,12 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
|
||||
final AccessibilityNodeInfo info = createAccessibilityNodeInfo();
|
||||
structure.setChildCount(1);
|
||||
final ViewStructure root = structure.newChild(0);
|
||||
populateVirtualStructure(root, provider, info, forAutofill);
|
||||
info.recycle();
|
||||
if (info != null) {
|
||||
populateVirtualStructure(root, provider, info, forAutofill);
|
||||
info.recycle();
|
||||
} else {
|
||||
Log.w(AUTOFILL_LOG_TAG, "AccessibilityNodeInfo is null.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user