Fixing a possible overflow in the >> 1 divide by two by using >>> 1 instead. Findbugs pointed this out>

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@636641 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Henri Yandell 2008-03-13 06:11:30 +00:00
parent 7fa45f4335
commit dcf024f3aa

View File

@ -679,7 +679,7 @@ private int binarySearch(int key) {
int high = size - 1;
while (low <= high) {
int mid = (low + high) >> 1;
int mid = (low + high) >>> 1;
int midVal = values[mid];
if (midVal < key) {