(buf_bytepos_to_charpos): Fix mixup introduced in commit b300052fb4
* src/marker.c (buf_bytepos_to_charpos): Don't compare byte-positions with char-positions.
This commit is contained in:
parent
2531721621
commit
b595b4598e
1 changed files with 3 additions and 3 deletions
|
@ -358,11 +358,11 @@ buf_bytepos_to_charpos (struct buffer *b, ptrdiff_t bytepos)
|
|||
{
|
||||
CONSIDER (tail->bytepos, tail->charpos);
|
||||
|
||||
/* If we are down to a range of 50 chars,
|
||||
/* If we are down to a range of DISTANCE bytes,
|
||||
don't bother checking any other markers;
|
||||
scan the intervening chars directly now. */
|
||||
if (best_above - bytepos < distance
|
||||
|| bytepos - best_below < distance)
|
||||
if (best_above_byte - bytepos < distance
|
||||
|| bytepos - best_below_byte < distance)
|
||||
break;
|
||||
else
|
||||
distance += BYTECHAR_DISTANCE_INCREMENT;
|
||||
|
|
Loading…
Add table
Reference in a new issue