poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cen...@apache.org
Subject svn commit: r1674954 - in /poi/trunk: src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc
Date Mon, 20 Apr 2015 18:16:30 GMT
Author: centic
Date: Mon Apr 20 18:16:30 2015
New Revision: 1674954

URL: http://svn.apache.org/r1674954
Log:
Fix possible ArrayIndexOutOfBoundsException seen with some word documents

Added:
    poi/trunk/test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc
Modified:
    poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java?rev=1674954&r1=1674953&r2=1674954&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java
(original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/converter/AbstractWordConverter.java
Mon Apr 20 18:16:30 2015
@@ -850,7 +850,7 @@ public abstract class AbstractWordConver
             String[] values = cr.getDropDownListValues();
             Integer defIndex = cr.getDropDownListDefaultItemIndex();
 
-            if ( values != null )
+            if ( values != null && values.length > 0 )
             {
                 processDropDownList( currentBlock, cr, values,
                         defIndex == null ? -1 : defIndex.intValue() );

Added: poi/trunk/test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc
URL: http://svn.apache.org/viewvc/poi/trunk/test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc?rev=1674954&view=auto
==============================================================================
Binary files poi/trunk/test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc
(added) and poi/trunk/test-data/document/au.edu.utas.www___data_assets_word_doc_0003_154335_International-Travel-Approval-Request-Form.doc
Mon Apr 20 18:16:30 2015 differ



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org


Mime
View raw message