comparison src/testdir/test_terminal.vim @ 19358:734ca70c1f12 v8.2.0237

patch 8.2.0237: crash when setting 'wincolor' on finished terminal window Commit: https://github.com/vim/vim/commit/7ba3b91e0385c848c773e2f2d803db01730e7786 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Feb 10 20:34:04 2020 +0100 patch 8.2.0237: crash when setting 'wincolor' on finished terminal window Problem: Crash when setting 'wincolor' on finished terminal window. (Bakudankun) Solution: Check that the vterm is not NULL. (Yasuhiro Matsumoto, closes #5607, closes #5610)
author Bram Moolenaar <Bram@vim.org>
date Mon, 10 Feb 2020 20:45:05 +0100
parents 77794a1d7e98
children f0033a10b613
comparison
equal deleted inserted replaced
19357:3e040669b87f 19358:734ca70c1f12
2368 call term_wait(buf, 100) " wait for terminal to vanish 2368 call term_wait(buf, 100) " wait for terminal to vanish
2369 2369
2370 call StopVimInTerminal(buf) 2370 call StopVimInTerminal(buf)
2371 call delete('XtermPopup') 2371 call delete('XtermPopup')
2372 endfunc 2372 endfunc
2373
2374 func Test_issue_5607()
2375 let wincount = winnr('$')
2376 exe 'terminal' &shell &shellcmdflag 'exit'
2377 let job = term_getjob(bufnr())
2378 call WaitForAssert({-> assert_equal("dead", job_status(job))})
2379
2380 let old_wincolor = &wincolor
2381 try
2382 set wincolor=
2383 finally
2384 let &wincolor = old_wincolor
2385 bw!
2386 endtry
2387 endfunc