/[Apache-SVN]
ViewVC logotype

Revision 1817796


Jump to revision: Previous Next
Author: gwoolsey
Date: Mon Dec 11 17:30:04 2017 UTC (6 years, 11 months ago)
Changed paths: 23
Log Message:
Bug 61882 - Some paths can create an XSSFColor instance with a null CTColor reference

Protect against this in the future by introducing a factory method to create XSSFColor instances from a CTColor instance and the associated workbook style indexed color map.

If the CTColor instance is null, the factory returns null.  All callers already are prepared for a null instance, but many had their own null check on the CTColor object.  This centralizes that.

This also further forces the requirement for the indexed color map.  Any time a color is created, the workbook or styleTable is available in the same context, so passing this is extra parameter is trivial and allows XSSFColor to properly reference custom/themed indexed colors.

Did not remove any methods yet, only deprecated them.  Changed the signature to one internal test-only constructor.

Changed paths

Path Details
Directorypoi/trunk/src/examples/src/org/apache/poi/xssf/usermodel/examples/CalendarDemo.java modified , text changed
Directorypoi/trunk/src/examples/src/org/apache/poi/xssf/usermodel/examples/WorkingWithRichText.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFBorderFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFCellStyle.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColor.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFColorScaleFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFCreationHelper.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFDataBarFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFFont.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFFontFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFPatternFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/extensions/XSSFCellBorder.java modified , text changed
Directorypoi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/extensions/XSSFCellFill.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFCellStyle.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFConditionalFormatting.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFDrawing.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFFont.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheet.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSimpleShape.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFTextParagraph.java modified , text changed
Directorypoi/trunk/src/ooxml/testcases/org/apache/poi/xssf/usermodel/extensions/TestXSSFCellFill.java modified , text changed

infrastructure at apache.org
ViewVC Help
Powered by ViewVC 1.1.26