diff options
author | Bram Moolenaar <Bram@vim.org> | 2021-12-20 21:35:59 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2021-12-20 21:35:59 +0000 |
commit | dab17a0689a2f31f69f428975f84b0c3c7ba3030 (patch) | |
tree | 6ab3b3865878fc6de89d4f2654d71b00c5fed833 /src/testdir | |
parent | 39713d3acbfb6673775158a0171c7389c07f25df (diff) | |
download | vim-git-dab17a0689a2f31f69f428975f84b0c3c7ba3030.tar.gz |
patch 8.2.3862: crash on exit with EXITFREE and using win_execute()v8.2.3862
Problem: Crash on exit with EXITFREE and using win_execute().
Solution: Also save and restore tp_topframe. (issue #9374)
Diffstat (limited to 'src/testdir')
-rw-r--r-- | src/testdir/test_execute_func.vim | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/testdir/test_execute_func.vim b/src/testdir/test_execute_func.vim index 06049c272..9146504e5 100644 --- a/src/testdir/test_execute_func.vim +++ b/src/testdir/test_execute_func.vim @@ -3,6 +3,7 @@ source view_util.vim source check.vim source vim9.vim +source term_util.vim func NestedEval() let nested = execute('echo "nested\nlines"') @@ -148,6 +149,27 @@ func Test_win_execute_other_tab() unlet xyz endfunc +func Test_win_execute_on_startup() + CheckRunVimInTerminal + + let lines =<< trim END + vim9script + [repeat('x', &columns)]->writefile('Xfile1') + silent tabedit Xfile2 + var id = win_getid() + silent tabedit Xfile3 + autocmd VimEnter * win_execute(id, 'close') + END + call writefile(lines, 'XwinExecute') + let buf = RunVimInTerminal('-p Xfile1 -Nu XwinExecute', {}) + + " this was crashing on exit with EXITFREE defined + call StopVimInTerminal(buf) + + call delete('XwinExecute') + call delete('Xfile1') +endfunc + func Test_execute_func_with_null() call assert_equal("", execute(test_null_string())) call assert_equal("", execute(test_null_list())) |