Mercurial > vim
view src/testdir/test_autochdir.vim @ 13250:fc33325c91c1 v8.0.1499
patch 8.0.1499: out-of-memory situation not correctly handled
commit https://github.com/vim/vim/commit/4b7e7bed6cb16c8256e6973418701cfb15b30b8e
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Feb 11 14:53:30 2018 +0100
patch 8.0.1499: out-of-memory situation not correctly handled
Problem: Out-of-memory situation not correctly handled. (Coverity)
Solution: Check for NULL value.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sun, 11 Feb 2018 15:00:06 +0100 |
parents | 03a6aeea2096 |
children | 90ab2d3ce11d |
line wrap: on
line source
" Test 'autochdir' behavior if !exists("+autochdir") finish endif func Test_set_filename() let cwd = getcwd() call test_autochdir() set acd new w samples/Xtest call assert_equal("Xtest", expand('%')) call assert_equal("samples", substitute(getcwd(), '.*/\(\k*\)', '\1', '')) bwipe! set noacd exe 'cd ' . cwd call delete('samples/Xtest') endfunc