OSDN Git Service

Workaround View.post issues to fix runtime crash
authorJorim Jaggi <jjaggi@google.com>
Wed, 29 Jul 2015 22:46:29 +0000 (15:46 -0700)
committerJorim Jaggi <jjaggi@google.com>
Wed, 29 Jul 2015 23:40:16 +0000 (23:40 +0000)
commit4a0e791cc0a71df2b0c6bae6e92a5f2100fb5841
tree9dead3f5f91a6178a565ce056c439fbac5473775
parenta6706627a9bf749cc591605272810e03983a9eea
Workaround View.post issues to fix runtime crash

Using View.post was really dangerous because when the view wasn't
attached, it got posted on the run queue of the *calling* thread.
However, that run queue was never executed until power down, and
then it was executed from the PowerManagerService thread, because
that was the calling thread when we posted it. Work around this by
using a solid Handler.

Bug: 22820787
Change-Id: Id60e49e859558993256fae0403236f2e4b6f1075
services/core/java/com/android/server/policy/keyguard/KeyguardServiceDelegate.java