< prev index next >

src/hotspot/share/prims/unsafe.cpp

Print this page

        

@@ -341,16 +341,15 @@
   oop p = JNIHandles::resolve(obj);
   Klass* k = java_lang_Class::as_Klass(JNIHandles::resolve_non_null(c));
   ValueKlass* vk = ValueKlass::cast(k);
   assert_and_log_unsafe_value_type_access(p, offset, vk);
   Handle p_h(THREAD, p);
-  bool in_heap;
-  oop v = vk->allocate_buffered_or_heap_instance(&in_heap, CHECK_NULL); // allocate instance
+  oop v = vk->allocate_instance(CHECK_NULL); // allocate instance
   vk->initialize(CHECK_NULL); // If field is a default value, value class might not be initialized yet
   vk->value_store(((char*)(oopDesc*)p_h()) + offset,
                   vk->data_for_oop(v),
-                  in_heap, true);                  
+                  true, true);
   return JNIHandles::make_local(env, v);
 } UNSAFE_END
 
 UNSAFE_ENTRY(void, Unsafe_PutValue(JNIEnv *env, jobject unsafe, jobject obj, jlong offset, jclass c, jobject value)) {
   oop v = JNIHandles::resolve(value);
< prev index next >