mirror of
https://github.com/rkd77/elinks.git
synced 2025-01-03 14:57:44 -05:00
In add_document_line, check expanded + line_pos rather than just
expanded when checking whether there are enough characters on the line to decrement expanded by 2. This fixes the problem reported by fonseca where the linked text was offset from the URI when there were backspaces earlier on the line.
This commit is contained in:
parent
eeb51bffea
commit
92c9b86374
@ -325,7 +325,7 @@ add_document_line(struct plain_renderer *renderer,
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (expanded - 2 >= 0) {
|
if ((expanded + line_pos) - 2 >= 0) {
|
||||||
/* Don't count the backspace character or the
|
/* Don't count the backspace character or the
|
||||||
* deleted character when returning the line's
|
* deleted character when returning the line's
|
||||||
* width or when expanding tabs. */
|
* width or when expanding tabs. */
|
||||||
|
Loading…
Reference in New Issue
Block a user