Skip to content

Commit 1097c06

Browse files
authored
Fix NullPointerException on Object class (#10950)
Fix NullPointerException on Object class Super class of Object class is null Co-authored-by: jean-philippe.bempel <jean-philippe.bempel@datadoghq.com>
1 parent aed9baf commit 1097c06

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

dd-java-agent/agent-debugger/src/main/java/com/datadog/debugger/agent/ConfigurationUpdater.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,8 @@ private List<Class<?>> detectRecordWithTypeAnnotation(
285285
for (Class<?> changedClass : changedClasses) {
286286
boolean addClass = true;
287287
try {
288-
if (changedClass.getSuperclass().getTypeName().equals("java.lang.Record")
288+
if (changedClass.getSuperclass() != null
289+
&& changedClass.getSuperclass().getTypeName().equals("java.lang.Record")
289290
&& Modifier.isFinal(changedClass.getModifiers())) {
290291
if (hasTypeAnnotationOnRecordComponent(changedClass)) {
291292
LOGGER.debug(

0 commit comments

Comments
 (0)