Skip to content

Commit cb6ca09

Browse files
authored
ion-java: fix build (#11586)
Fixes build failure for `ion-java`: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=63457 `withAnnotationIteratorReuseEnabled` was removed from `IonReaderBuilder`. Removing this will cause the build to succeed. `NullPointerException`, `ArrayIndexOutOfBoundsException`, and `AssertionError` should not leak from the library; such leaks would be useful to find during fuzzing.
1 parent 45f5c2f commit cb6ca09

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

projects/ion-java/project-parent/fuzz-targets/src/test/java/com/example/IonReaderFuzzer.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,11 @@ void myFuzzTest(FuzzedDataProvider data) {
3131
try {
3232
IonReader reader = IonReaderBuilder
3333
.standard()
34-
.withAnnotationIteratorReuseEnabled(data.consumeBoolean())
3534
.withIncrementalReadingEnabled(data.consumeBoolean())
3635
.build(data.consumeRemainingAsString());
3736
read(reader);
3837
reader.close();
39-
} catch (IOException | NullPointerException | IllegalStateException | IllegalArgumentException | ArrayIndexOutOfBoundsException | IonException | AssertionError e) {
38+
} catch (IOException | IllegalStateException | IllegalArgumentException | IonException e) {
4039
// Need to be caught to get more interesting findings.
4140
}
4241
}
@@ -49,4 +48,4 @@ void read(IonReader reader) {
4948
reader.stringValue();
5049
reader.stepOut();
5150
}
52-
}
51+
}

0 commit comments

Comments
 (0)