Fix the previous fix: skip algo if the guessed index was out of bounds.
Setting to the last item would miss checking the last item itself,
so the method would return -1 by mistake if the last item was the one we
were looking for.
Arguably it would be faster to do a reverse search in that case though.
Note that removing the -1 in qMin wouldn't work either, bwdIt==end skips
all backward search.
CCMAIL: dvratil@kde.org