'u->mark_begin_lineno' is being used as the length of the insertion.
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5375
35c25a1d-7b9e-4130-9fde-
d3aeb78583b8
+2015-10-28 Benno Schulenberg <bensberg@justemail.net>
+ * src/text.c (do_redo): For an INSERT, 'u->mark_begin_lineno' is not
+ an actual line number, so spoof it. It can be spoofed, because 'f'
+ is not used for the INSERT case. This fixes Savannah bug #45524.
+
2015-10-27 Benno Schulenberg <bensberg@justemail.net>
* src/move.c (do_next_word): Rewrite this function to use the same
logic as do_prev_word(), reducing its number of lines to half.
return;
}
- filestruct *f = fsfromline(u->mark_begin_lineno);
+ filestruct *f = fsfromline(u->type == INSERT ? 1 : u->mark_begin_lineno);
if (!f) {
statusbar(_("Internal error: can't match line %d. Please save your work."), u->mark_begin_lineno);
return;