Skip to content

Commit

Permalink
fix: NoSuchMethodError closeQuietly(java.io.Closeable[]) (#6377)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremylong authored Jan 14, 2024
1 parent a6c3909 commit 0d96989
Showing 1 changed file with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,20 @@ public JsonArrayCveItemSource(InputStream inputStream) throws IOException {

@Override
public void close() throws Exception {
IOUtils.closeQuietly(jsonParser, inputStream);
if (jsonParser != null) {
try {
jsonParser.close();
} catch (IOException ex) {
//ignore
}
}
if (inputStream != null) {
try {
inputStream.close();
} catch (IOException ex) {
//ignore
}
}
}

@Override
Expand Down

0 comments on commit 0d96989

Please sign in to comment.