OSDN Git Service

Fix potential linear alloc memory leak
authorMathieu Chartier <mathieuc@google.com>
Wed, 2 Mar 2016 18:30:23 +0000 (10:30 -0800)
committerMathieu Chartier <mathieuc@google.com>
Wed, 2 Mar 2016 18:47:20 +0000 (10:47 -0800)
commit5b83050affa6a3b1d3863c0b903f9d48fe4aefb2
tree6ffce3adefced9b6ab9f019327e542e0535e225e
parenta71ec6419d9e80b354de721003c8b7929d224a49
Fix potential linear alloc memory leak

Previously, if we created a linear alloc for a class loader but
never created the class table, the linear alloc would never get
freed since it would have no corresponding ClassLoaderData.

Fixes valgrind-test-art-host-gtest-oat_test

Bug: 27384882
Change-Id: Ic8f35b58c3117127a39521b6b9d25ef12c72040c
runtime/class_linker.cc
runtime/class_linker.h
runtime/stack.cc