Fix a bug in secondary index entry matter/antimatter reconciliation during upsert

Change-Id: I5d5c4c44f49308757e05bed3a20475abdd3d38e7
Reviewed-on: https://asterix-gerrit.ics.uci.edu/1488
Sonar-Qube: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Tested-by: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
BAD: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Reviewed-by: abdullah alamoudi <bamousaa@gmail.com>
diff --git a/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/operators/LSMSecondaryUpsertOperatorNodePushable.java b/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/operators/LSMSecondaryUpsertOperatorNodePushable.java
index 1d9ceb4..eab9cc7 100644
--- a/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/operators/LSMSecondaryUpsertOperatorNodePushable.java
+++ b/asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/operators/LSMSecondaryUpsertOperatorNodePushable.java
@@ -63,10 +63,10 @@
     }
 
     public static boolean equals(byte[] a, int aOffset, int aLength, byte[] b, int bOffset, int bLength) {
-        if (a.length != b.length) {
+        if (aLength != bLength) {
             return false;
         }
-        for (int i = 0; i < a.length; i++) {
+        for (int i = 0; i < aLength; i++) {
             if (a[aOffset + i] != b[bOffset + i]) {
                 return false;
             }