Minor but critical fix to binary search (reverse)
Merge pull request #206 from ssim/search_bug_fix

Minor but critical fix to binary search (reverse)