You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@poi.apache.org by fa...@apache.org on 2018/12/18 23:26:49 UTC

svn commit: r1849250 - /poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java

Author: fanningpj
Date: Tue Dec 18 23:26:49 2018
New Revision: 1849250

URL: http://svn.apache.org/viewvc?rev=1849250&view=rev
Log:
fix index check in HemfDraw

Modified:
    poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java?rev=1849250&r1=1849249&r2=1849250&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java (original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hemf/record/emf/HemfDraw.java Tue Dec 18 23:26:49 2018
@@ -783,7 +783,7 @@ public class HemfDraw {
                         int mode2 = leis.readUByte();
                         int mode3 = leis.readUByte();
                         assert(mode2 == 0x04 && (mode3 == 0x04 || mode3 == 0x05));
-                        if ((i + 2) > points.length) {
+                        if ((i + 2) >= points.length) {
                             throw new IllegalStateException("Points index causes index out of bounds");
                         }
                         poly.curveTo(



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