diff options
author | Ian Rogers <irogers@google.com> | 2014-04-22 11:42:59 -0700 |
---|---|---|
committer | Ian Rogers <irogers@google.com> | 2014-04-22 14:52:19 -0700 |
commit | 987560fee798e48fb725c44b796d8ca7a5872ad6 (patch) | |
tree | d61f35a129847f3f5fbed1436649e75acd940b3f /runtime/jni_internal.h | |
parent | 44b0053fdb7ad8a30138d29f714172a7dc69efb8 (diff) | |
download | art-987560fee798e48fb725c44b796d8ca7a5872ad6.zip art-987560fee798e48fb725c44b796d8ca7a5872ad6.tar.gz art-987560fee798e48fb725c44b796d8ca7a5872ad6.tar.bz2 |
Remove support for app JNI workarounds.
Change-Id: I4396df7e93fcace4b5b19c2c387e5c30089182a6
Diffstat (limited to 'runtime/jni_internal.h')
-rw-r--r-- | runtime/jni_internal.h | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/runtime/jni_internal.h b/runtime/jni_internal.h index 42796db..ec911b2 100644 --- a/runtime/jni_internal.h +++ b/runtime/jni_internal.h @@ -110,9 +110,6 @@ class JavaVMExt : public JavaVM { // Extra diagnostics. std::string trace; - // Used to provide compatibility for apps that assumed direct references. - bool work_around_app_jni_bugs; - // Used to hold references to pinned primitive arrays. Mutex pins_lock DEFAULT_MUTEX_ACQUIRED_AFTER; ReferenceTable pin_table GUARDED_BY(pins_lock); @@ -149,7 +146,7 @@ struct JNIEnvExt : public JNIEnv { void PopFrame(); template<typename T> - T AddLocalReference(mirror::Object* obj, bool jni_work_arounds) + T AddLocalReference(mirror::Object* obj) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_); static Offset SegmentStateOffset(); @@ -216,7 +213,7 @@ class ScopedJniEnvLocalRefState { }; template<typename T> -inline T JNIEnvExt::AddLocalReference(mirror::Object* obj, bool jni_work_arounds) { +inline T JNIEnvExt::AddLocalReference(mirror::Object* obj) { IndirectRef ref = locals.Add(local_ref_cookie, obj); // TODO: fix this to understand PushLocalFrame, so we can turn it on. @@ -231,9 +228,6 @@ inline T JNIEnvExt::AddLocalReference(mirror::Object* obj, bool jni_work_arounds } } - if (jni_work_arounds) { - return reinterpret_cast<T>(obj); - } return reinterpret_cast<T>(ref); } |