diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/option.c | 4 | ||||
-rw-r--r-- | src/testdir/test_options.vim | 16 | ||||
-rw-r--r-- | src/version.c | 2 |
3 files changed, 22 insertions, 0 deletions
diff --git a/src/option.c b/src/option.c index 48432bb32..5ef346c8d 100644 --- a/src/option.c +++ b/src/option.c @@ -3367,7 +3367,11 @@ set_init_1(int clean_arg) mustfree = FALSE; # ifdef UNIX if (*names[n] == NUL) +# ifdef MACOS_X + p = (char_u *)"/private/tmp"; +# else p = (char_u *)"/tmp"; +# endif else # endif p = vim_getenv((char_u *)names[n], &mustfree); diff --git a/src/testdir/test_options.vim b/src/testdir/test_options.vim index 5d2033a5d..0f2908fcb 100644 --- a/src/testdir/test_options.vim +++ b/src/testdir/test_options.vim @@ -332,3 +332,19 @@ func Test_set_indentexpr() call assert_equal('', &indentexpr) bwipe! endfunc + +func Test_backupskip() + if has("mac") + call assert_match('/private/tmp/\*', &bsk) + elseif has("unix") + call assert_match('/tmp/\*', &bsk) + endif + + let bskvalue = substitute(&bsk, '\\', '/', 'g') + for var in ['$TEMPDIR', '$TMP', '$TEMP'] + if exists(var) + let varvalue = substitute(expand(var), '\\', '/', 'g') + call assert_match(varvalue . '.\*', bskvalue) + endif + endfor +endfunc diff --git a/src/version.c b/src/version.c index fdaa1dc6c..8d7049d5f 100644 --- a/src/version.c +++ b/src/version.c @@ -763,6 +763,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1704, +/**/ 1703, /**/ 1702, |