Protect bubble gesture monitor against re-entrant calls
We were seeing an NPE when stopping bubble gesture monitor when stack view was collapsing. The cause seems to be triggered by a re-entrant call that originates from BatchedInputEventReceiver sending out all unconsumed touch events when it is disposed. Some of these unconsumed touch events can trigger another collapse call. Which tries to stop the gesture monitor again. Since we clean up the reference to input event receivers after dispose() call, the references are still there. And this triggers another attempt to dispose them. This now leads to an NPE and the input event receivers are already cleared out. Fixing this by ensuring we clear out the references to the input event receivers before we call dispose on them. To protect against re-entrant calls. Bug: 432344114 Test: manual, check that bubbles input monitor stops (regular home gesture works) when: - bubbles are expanded and collapsed - bubbles are expanded and notif panel is expanded on top Flag: EXEMPT, bugfix Change-Id: I7e882892a4c1cdb4f8ed0fa252125032feeb1806
Loading
Please register or sign in to comment