patches: re-fix B6 nlines < 128 -> 512 (lost in revert)
Fix was accidentally reverted when reverting the broken B5 goto fix. Both line_starts[512]/line_ends[512] arrays and the main while loop guard use 512; the trailing-line check must also use 512 to avoid silently dropping the last line in buffers with 128-511 lines.
This commit is contained in:
@@ -269,7 +269,7 @@ index c9fe93a57b..f7574efb39 100644
|
|||||||
+ byte_pos++;
|
+ byte_pos++;
|
||||||
+ char_pos++;
|
+ char_pos++;
|
||||||
+ }
|
+ }
|
||||||
+ if (char_pos > lstart && nlines < 128)
|
+ if (char_pos > lstart && nlines < 512)
|
||||||
+ {
|
+ {
|
||||||
+ line_starts[nlines] = lstart;
|
+ line_starts[nlines] = lstart;
|
||||||
+ line_ends[nlines] = char_pos;
|
+ line_ends[nlines] = char_pos;
|
||||||
|
|||||||
Reference in New Issue
Block a user