Skip to content

Commit 7191aec

Browse files
committed
Sync with latest jackson-core
1 parent ea62556 commit 7191aec

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/main/java/com/fasterxml/jackson/dataformat/xml/deser/FromXmlParser.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.fasterxml.jackson.dataformat.xml.deser;
22

33
import java.io.IOException;
4+
import java.io.UncheckedIOException;
45
import java.io.Writer;
56
import java.math.BigDecimal;
67
import java.math.BigInteger;
@@ -12,6 +13,7 @@
1213

1314
import com.fasterxml.jackson.core.*;
1415
import com.fasterxml.jackson.core.base.ParserMinimalBase;
16+
import com.fasterxml.jackson.core.exc.StreamConstraintsException;
1517
import com.fasterxml.jackson.core.io.IOContext;
1618
import com.fasterxml.jackson.core.io.NumberInput;
1719
import com.fasterxml.jackson.core.util.ByteArrayBuilder;
@@ -630,7 +632,12 @@ public boolean isExpectedNumberIntToken()
630632
}
631633
}
632634
// finally, need BigInteger
633-
streamReadConstraints().validateIntegerLength(text.length());
635+
try {
636+
streamReadConstraints().validateIntegerLength(text.length());
637+
} catch (StreamConstraintsException e) {
638+
// Ugh. This method in API ought to expose IOException
639+
throw new UncheckedIOException(e);
640+
}
634641
_numberBigInt = NumberInput.parseBigInteger(
635642
text, isEnabled(StreamReadFeature.USE_FAST_BIG_NUMBER_PARSER));
636643
_numTypesValid = NR_BIGINT;

0 commit comments

Comments
 (0)