mirror of https://github.com/google/oss-fuzz.git
jackson-datatypes-collections: Catch known exceptions (#11310)
This PR catches some known exceptions which are missed before. This PR solves https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=64612, https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=64614, https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=64640 and https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=64642. Signed-off-by: Arthur Chan <arthur.chan@adalogics.com>
This commit is contained in:
parent
76f3c27b87
commit
22c941296e
|
@ -38,7 +38,7 @@ public class EclipseCollectionsDeserializerFuzzer {
|
|||
String value = data.consumeRemainingAsString();
|
||||
mapper.readValue(value, type);
|
||||
mapper.readTree(value);
|
||||
} catch (IOException e) {
|
||||
} catch (IOException | IllegalArgumentException e) {
|
||||
// Known exception
|
||||
}
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ public class GuavaDeserializerFuzzer {
|
|||
TypeReference type = data.pickValue(choice);
|
||||
String value = data.consumeRemainingAsString();
|
||||
mapper.readValue(value, type);
|
||||
} catch (IOException e) {
|
||||
} catch (IOException | IllegalArgumentException e) {
|
||||
// Known exception
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue