diff options
author | riddle_hsu <riddle_hsu@htc.com> | 2015-03-19 01:11:55 +0800 |
---|---|---|
committer | Riddle Hsu <riddle_hsu@htc.com> | 2015-03-18 19:01:36 +0000 |
commit | d3b371755df509cabbc5b4451df83309be5439b0 (patch) | |
tree | 70d3cd4df91e053459d63cdbc1d1a41c1a25f45b /rs/java/android/renderscript/RenderScript.java | |
parent | 28e6aeca3aad075ef4fd7aab08cd1ad1ff9eb555 (diff) |
Fix no vibration during shutdown.
In ShutdownThread:rebootOrShutdown, the vibrator is created
by "new SystemVibrator()" which will use default constructor
of Vibrator.
And because system server is not bound application,
ActivityThread.currentPackageName will be null.
Then the member mPackageName of Vibrator is null.
When doing vibration:
VibratorService.startVibrationLocked
-> mAppOpsService.startOperation
-> getOpsLocked (null package will get null op)
-> return MODE_ERRORED
-> no vibration
https://code.google.com/p/android/issues/detail?id=160830
Pass null context in SystemServer.performPendingShutdown
because vibrator service is not ready, and from the call
sequence, there is no available context to use.
Change-Id: I3e0175ba6dc2e1a92787873eda4461fba6e89783
Diffstat (limited to 'rs/java/android/renderscript/RenderScript.java')
0 files changed, 0 insertions, 0 deletions