diff --git a/src/documentation/content/xdocs/status.xml b/src/documentation/content/xdocs/status.xml index e83b0f51d..7f0d31a09 100644 --- a/src/documentation/content/xdocs/status.xml +++ b/src/documentation/content/xdocs/status.xml @@ -34,6 +34,7 @@ + 51474 - SXSSF handling for null strings 48294 - Fixed HSSFWorkbook.setSheetOrder() to respect inter-sheet references 51448 - Avoid exception when evaluating workbooks with more than 256 sheets 51458 - Correct BitField wrapping when setting large values diff --git a/src/ooxml/java/org/apache/poi/xssf/streaming/SXSSFSheet.java b/src/ooxml/java/org/apache/poi/xssf/streaming/SXSSFSheet.java index 96af6932b..bb5d8ac81 100644 --- a/src/ooxml/java/org/apache/poi/xssf/streaming/SXSSFSheet.java +++ b/src/ooxml/java/org/apache/poi/xssf/streaming/SXSSFSheet.java @@ -22,7 +22,6 @@ import java.util.Iterator; import java.util.TreeMap; import java.util.Map; -import org.apache.poi.hpsf.IllegalPropertySetDataException; import org.apache.poi.ss.usermodel.*; import org.apache.poi.ss.util.CellReference; @@ -1402,6 +1401,10 @@ public class SXSSFSheet implements Sheet, Cloneable //Taken from jdk1.3/src/javax/swing/text/html/HTMLWriter.java protected void outputQuotedString(String s) throws IOException { + if(s == null || s.length() == 0) { + return; + } + char[] chars=s.toCharArray(); int last = 0; int length=s.length();