undo: use the correct original fusion point when unjoining two lines

When a <Backspace> did the join, 'head' and 'tail' are not the same.

This fixes https://savannah.gnu.org/bugs/?57916.

Bug existed since commit 7cf08b93 from yesterday.
master
Benno Schulenberg 2020-02-28 17:02:34 +01:00
parent 132ed5c8f0
commit 7d0b7e47c1
1 changed files with 1 additions and 1 deletions

View File

@ -556,7 +556,7 @@ void do_undo(void)
goto_line_posx(openfile->filebot->lineno, 0);
break;
}
line->data[u->head_x] = '\0';
line->data[u->tail_x] = '\0';
intruder = make_new_node(line);
intruder->data = copy_of(u->strdata);
splice_node(line, intruder);