diff --git a/src/undo.c b/src/undo.c index 7f1aa8ad87517ea0c744f9116399e4565714cba5..cb51c996c22e6c52e5c996d22a73ee94abaceca9 100644 --- a/src/undo.c +++ b/src/undo.c @@ -1918,6 +1918,8 @@ undo_time(step, sec, absolute) last->uh_alt_next = uhp; uhp->uh_alt_prev = last; + if (curbuf->b_u_oldhead == uhp) + curbuf->b_u_oldhead = last; uhp = last; if (uhp->uh_next != NULL) uhp->uh_next->uh_prev = uhp;