summaryrefslogtreecommitdiff
path: root/src/testdir/test_channel.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-02-10 22:23:26 +0100
committerBram Moolenaar <Bram@vim.org>2019-02-10 22:23:26 +0100
commit6524068ff3252f1373807f1ebfde21408cef624e (patch)
tree016c761632389af45db753da47049f2d0ce0a688 /src/testdir/test_channel.vim
parent31b816042fca879b11965ddd75287732563ba698 (diff)
downloadvim-git-6524068ff3252f1373807f1ebfde21408cef624e.tar.gz
patch 8.1.0889: MS-Windows: a channel write may hangv8.1.0889
Problem: MS-Windows: a channel write may hang. Solution: Check for WriteFile() not writing anything. (Yasuhiro Matsumoto, closes #3920)
Diffstat (limited to 'src/testdir/test_channel.vim')
-rw-r--r--src/testdir/test_channel.vim14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/testdir/test_channel.vim b/src/testdir/test_channel.vim
index 2aef3e1dc..becd5484f 100644
--- a/src/testdir/test_channel.vim
+++ b/src/testdir/test_channel.vim
@@ -2003,6 +2003,20 @@ func Test_raw_large_data()
endtry
endfunc
+func Test_no_hang_windows()
+ if !has('job') || !has('win32')
+ return
+ endif
+
+ try
+ let job = job_start(s:python . " test_channel_pipe.py busy",
+ \ {'mode': 'raw', 'drop': 'never', 'noblock': 0})
+ call assert_fails('call ch_sendraw(job, repeat("X", 80000))', 'E631:')
+ finally
+ call job_stop(job)
+ endtry
+endfunc
+
func Test_job_exitval_and_termsig()
if !has('unix')
return