Pārlūkot izejas kodu

Bug 66425: Avoid Exceptions found via oss-fuzz

We try to avoid throwing NullPointerExceptions or endless allocations,
but it was possible to trigger one here with a specially
crafted input-file

Should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62745

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1912795 13f79535-47bb-0310-9956-ffa450edef68
tags/REL_5_2_5
Dominik Stadler pirms 7 mēnešiem
vecāks
revīzija
eb11f3324f

+ 2
- 2
poi-ooxml/src/main/java/org/apache/poi/xdgf/usermodel/section/geometry/LineTo.java Parādīt failu

for (CellType cell : row.getCellArray()) { for (CellType cell : row.getCellArray()) {
String cellName = cell.getN(); String cellName = cell.getN();


if (cellName.equals("X")) {
if ("X".equals(cellName)) {
x = XDGFCell.parseDoubleValue(cell); x = XDGFCell.parseDoubleValue(cell);
} else if (cellName.equals("Y")) {
} else if ("Y".equals(cellName)) {
y = XDGFCell.parseDoubleValue(cell); y = XDGFCell.parseDoubleValue(cell);
} else { } else {
throw new POIXMLException("Invalid cell '" + cellName throw new POIXMLException("Invalid cell '" + cellName

Binārs
test-data/diagram/clusterfuzz-testcase-minimized-POIVisioFuzzer-5981064948219904.vsdx Parādīt failu


Binārs
test-data/spreadsheet/stress.xls Parādīt failu


Notiek ielāde…
Atcelt
Saglabāt