shada: Save current cursor position before saving jumps

This commit is contained in:
ZyX
2016-07-17 15:28:14 +03:00
parent d8a97d7b79
commit 81ef9f55ae
2 changed files with 17 additions and 1 deletions

View File

@@ -2591,9 +2591,12 @@ static ShaDaWriteResult shada_write(ShaDaWriteDef *const sd_writer,
// Initialize jump list
const void *jump_iter = NULL;
do {
xfmark_T fm;
setpcmark();
cleanup_jumplist();
xfmark_T fm;
jump_iter = mark_jumplist_iter(jump_iter, curwin, &fm);
const buf_T *const buf = (fm.fmark.fnum == 0
? NULL
: buflist_findnr(fm.fmark.fnum));