correct binary search of rotated pivot