OSDN Git Service

Change DecodeWeakGlobal to DecodeJObject for class unloading
authorMathieu Chartier <mathieuc@google.com>
Fri, 2 Oct 2015 00:08:44 +0000 (17:08 -0700)
committerMathieu Chartier <mathieuc@google.com>
Fri, 2 Oct 2015 00:32:08 +0000 (17:32 -0700)
commit4843bd5a0ba1d85e73f6e0ed7a24fa4a344cccb0
tree0ab2126275b298ba877440dd6b556381af587ce1
parent25217af2a7cae96b32ba566aaf697288f3374c99
Change DecodeWeakGlobal to DecodeJObject for class unloading

DecodeWeakGlobal returns the sentinel object for cleared JNI weak
globals. This was causing a memory leak since it wouldn't delete
class tables and linear allocs due to never returning null. The bug
was found by yamauchi.

Bug: 22720414

Change-Id: Iff4681495232b9a9756dbdb51d10ea72691a85dd
runtime/class_linker.cc