1 Star 0 Fork 13

佛系少年中二/openjdk-21

forked from src-openEuler/openjdk-21 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Backport-of-JDK-8332720-ubsan-instanceKlass.cpp:3550.patch 1.39 KB
一键复制 编辑 原始数据 按行查看 历史
wuyafang 提交于 2024-10-14 11:38 . sync bishengjdk21 patches
Subject: Backport of JDK-8332720 ubsan: instanceKlass.cpp:3550:76: runtime error: member call on null pointer of type 'struct Array'
---
src/hotspot/share/oops/instanceKlass.cpp | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/src/hotspot/share/oops/instanceKlass.cpp b/src/hotspot/share/oops/instanceKlass.cpp
index 6f0d521b9..edbca5df7 100644
--- a/src/hotspot/share/oops/instanceKlass.cpp
+++ b/src/hotspot/share/oops/instanceKlass.cpp
@@ -3587,11 +3587,13 @@ void InstanceKlass::print_on(outputStream* st) const {
}
}
st->print(BULLET"method ordering: "); method_ordering()->print_value_on(st); st->cr();
- st->print(BULLET"default_methods: "); default_methods()->print_value_on(st); st->cr();
- if (Verbose && default_methods() != nullptr) {
- Array<Method*>* method_array = default_methods();
- for (int i = 0; i < method_array->length(); i++) {
- st->print("%d : ", i); method_array->at(i)->print_value(); st->cr();
+ if (default_methods() != nullptr) {
+ st->print(BULLET"default_methods: "); default_methods()->print_value_on(st); st->cr();
+ if (Verbose) {
+ Array<Method*>* method_array = default_methods();
+ for (int i = 0; i < method_array->length(); i++) {
+ st->print("%d : ", i); method_array->at(i)->print_value(); st->cr();
+ }
}
}
if (default_vtable_indices() != nullptr) {
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/Autistic_boyya/openjdk-21.git
[email protected]:Autistic_boyya/openjdk-21.git
Autistic_boyya
openjdk-21
openjdk-21
master

搜索帮助