From a09b06d6b453e037bba167b6b68960d63d12668c Mon Sep 17 00:00:00 2001 From: Ti Chi Robot Date: Tue, 7 Mar 2023 19:22:23 +0800 Subject: [PATCH] fix byte overflow (#729) Signed-off-by: shiyuhang <1136742008@qq.com> Co-authored-by: shiyuhang <1136742008@qq.com> --- src/main/java/org/tikv/common/codec/RowV2.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/tikv/common/codec/RowV2.java b/src/main/java/org/tikv/common/codec/RowV2.java index 44891e4e917..6893894a7bd 100644 --- a/src/main/java/org/tikv/common/codec/RowV2.java +++ b/src/main/java/org/tikv/common/codec/RowV2.java @@ -147,7 +147,7 @@ private int binarySearch(int i, int j, long colID) { if (this.large) { v = this.colIDs32[h]; } else { - v = this.colIDs[h]; + v = this.colIDs[h] & 0xFF; } if (v < colID) { i = h + 1;