]> source.dussan.org Git - poi.git/commit
60184 - invalid OOXML produced when XSSFFont.getFamily() called with no families...
authorGreg Woolsey <gwoolsey@apache.org>
Fri, 5 May 2017 21:50:59 +0000 (21:50 +0000)
committerGreg Woolsey <gwoolsey@apache.org>
Fri, 5 May 2017 21:50:59 +0000 (21:50 +0000)
commit1a4724c9b1340609a5a76dbdeaa0d0511768781c
tree121d0a60b9e47aae1d15009a347ce830d650eb7a
parentf495d78352a3e5f8110921714d9c06904003f99f
60184 - invalid OOXML produced when XSSFFont.getFamily() called with no families defined

Fix to stop creating an empty family when none exist, just use the existing logic to return NOT_APPLICABLE.  Creating the empty element produces XML that doesn't comply with the XSD.

Alternative would have been to set the family int value for the new family, but this way checking the value doesn't change the output, which is my preferred behavior.  No quantum effects!

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1794111 13f79535-47bb-0310-9956-ffa450edef68
src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFFont.java