diff options
author | PJ Fanning <fanningpj@apache.org> | 2017-06-24 07:30:07 +0000 |
---|---|---|
committer | PJ Fanning <fanningpj@apache.org> | 2017-06-24 07:30:07 +0000 |
commit | 6df937ec6bde5aad5dbcd9cbc558cc623b24a406 (patch) | |
tree | 645f0b69eb2610f93fd74d60963794c1f8170c5b /src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java | |
parent | 3e6d942b958744d78900efd9eb923cbbd190a73a (diff) | |
download | poi-6df937ec6bde5aad5dbcd9cbc558cc623b24a406.tar.gz poi-6df937ec6bde5aad5dbcd9cbc558cc623b24a406.zip |
Add StaxHelper to ensure that StAX parsers have sensible defaults, including settings to avoid XML Entity Expansion issues
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799734 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java')
-rw-r--r-- | src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java b/src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java index ad2553fbe7..a188e6e255 100644 --- a/src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java +++ b/src/java/org/apache/poi/sl/draw/geom/PresetGeometries.java @@ -37,6 +37,7 @@ import javax.xml.stream.events.XMLEvent; import org.apache.poi.sl.draw.binding.CTCustomGeometry2D; import org.apache.poi.util.POILogFactory; import org.apache.poi.util.POILogger; +import org.apache.poi.util.StaxHelper; /** * @@ -59,7 +60,7 @@ public class PresetGeometries extends LinkedHashMap<String, CustomGeometry> { } }; - XMLInputFactory staxFactory = XMLInputFactory.newFactory(); + XMLInputFactory staxFactory = StaxHelper.newXMLInputFactory(); XMLEventReader staxReader = staxFactory.createXMLEventReader(is); XMLEventReader staxFiltRd = staxFactory.createFilteredReader(staxReader, startElementFilter); // ignore StartElement: |