You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by GitBox <gi...@apache.org> on 2021/05/14 18:58:29 UTC

[GitHub] [phoenix] joshelser commented on a change in pull request #1220: PHOENIX-6453 Possible ArrayIndexOutOfBoundsException while preparing …

joshelser commented on a change in pull request #1220:
URL: https://github.com/apache/phoenix/pull/1220#discussion_r632735770



##########
File path: phoenix-core/src/main/java/org/apache/phoenix/util/ScanUtil.java
##########
@@ -363,10 +363,12 @@ public static void setTimeRange(Scan scan, long minStamp, long maxStamp) {
         }
         int[] position = new int[slots.size()];
         int maxLength = 0;
+        int slotEndingFieldPos = 0;
         for (int i = 0; i < position.length; i++) {
             position[i] = bound == Bound.LOWER ? 0 : slots.get(i).size()-1;
             KeyRange range = slots.get(i).get(position[i]);
-            Field field = schema.getField(i + slotSpan[i]);
+            slotEndingFieldPos = slotEndingFieldPos + slotSpan[i] + (i>0? 1: 0);

Review comment:
       👍🏼




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org