Skip to content

Commit 23f40d9

Browse files
authored
Add NPE check for dealing with another OSS-Fuzz found edge case (FasterXML#439)
1 parent 3ea7cda commit 23f40d9

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

ion/src/main/java/com/fasterxml/jackson/dataformat/ion/IonParser.java

+6-1
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,12 @@ public Object getEmbeddedObject() throws IOException {
509509
}
510510
case BLOB:
511511
case CLOB:
512-
return _reader.newBytes();
512+
try {
513+
return _reader.newBytes();
514+
} catch (NullPointerException e) {
515+
// 02-Jan-2024, tatu: OSS-Fuzz#65479 points to NPE ^^^
516+
return _reportCorruptContent(e);
517+
}
513518
// What about CLOB?
514519
default:
515520
}

0 commit comments

Comments
 (0)