diff options
author | 2025-03-11 03:24:14 -0700 | |
---|---|---|
committer | 2025-03-20 03:50:21 -0700 | |
commit | 59aaec4d51436995ace22c4bd6f35ff7f6f8aaf4 (patch) | |
tree | 4241d68db637844d86522d0445813d711ff5e8a4 /runtime/class_linker.cc | |
parent | a23f36390858d148e7ab2cc8ff159b138946595e (diff) |
Revert^2 "Call target method in accessor MHs when it is set."
Previous LUCI crashes were due to b/404465902, which was
fixed in aosp/3551420.
Bug: 297147201
Test: ART_HEAP_POISONING=true art/test/testrunner/testrunner.py -b \
--host --baseline --debug --gcstress --64
Test: art/test/testrunner/testrunner.py -b \
--host --baseline --debug --gcstress --64
Change-Id: If93b9c6559ac8ddbc3211df1cbc4dec192cb054a
Diffstat (limited to 'runtime/class_linker.cc')
-rw-r--r-- | runtime/class_linker.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc index 70eea2d268..009d705caf 100644 --- a/runtime/class_linker.cc +++ b/runtime/class_linker.cc @@ -10569,7 +10569,7 @@ ObjPtr<mirror::MethodHandle> ClassLinker::ResolveMethodHandleForField( return nullptr; } - StackHandleScope<4> hs(self); + StackHandleScope<5> hs(self); ObjPtr<mirror::Class> array_of_class = GetClassRoot<mirror::ObjectArray<mirror::Class>>(this); Handle<mirror::ObjectArray<mirror::Class>> method_params(hs.NewHandle( mirror::ObjectArray<mirror::Class>::Alloc(self, array_of_class, num_params))); @@ -10629,7 +10629,8 @@ ObjPtr<mirror::MethodHandle> ClassLinker::ResolveMethodHandleForField( return nullptr; } - uintptr_t target = reinterpret_cast<uintptr_t>(target_field); + Handle<mirror::Field> target(hs.NewHandle( + mirror::Field::CreateFromArtField(self, target_field, /*force_resolve=*/ true))); return mirror::MethodHandleImpl::Create(self, target, kind, method_type); } |