From 85741677c86f7686e3597a310f8059608e7816fb Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sat, 15 Apr 2023 13:31:30 +0800 Subject: vim-patch:8.2.0634: crash with null partial and blob Problem: Crash with null partial and blob. Solution: Check for NULL pointer. Add more tests. (Yegappan Lakshmanan, closes vim/vim#5984) https://github.com/vim/vim/commit/92b83ccfda7a1d654ccaaf161a9c8a8e01fbcf76 Co-authored-by: Bram Moolenaar --- test/old/testdir/test_vimscript.vim | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'test/old/testdir/test_vimscript.vim') diff --git a/test/old/testdir/test_vimscript.vim b/test/old/testdir/test_vimscript.vim index 5988d6ed71..b5578f7f68 100644 --- a/test/old/testdir/test_vimscript.vim +++ b/test/old/testdir/test_vimscript.vim @@ -6508,9 +6508,17 @@ func Test_type() call assert_equal(v:t_float, type(0.0)) call assert_equal(v:t_bool, type(v:false)) call assert_equal(v:t_bool, type(v:true)) + " call assert_equal(v:t_none, type(v:none)) + " call assert_equal(v:t_none, type(v:null)) call assert_equal(v:t_string, type(v:_null_string)) call assert_equal(v:t_list, type(v:_null_list)) call assert_equal(v:t_dict, type(v:_null_dict)) + if has('job') + call assert_equal(v:t_job, type(test_null_job())) + endif + if has('channel') + call assert_equal(v:t_channel, type(test_null_channel())) + endif call assert_equal(v:t_blob, type(v:_null_blob)) call assert_equal(0, 0 + v:false) -- cgit