diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-01-06 17:53:38 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-01-06 17:53:38 +0100 |
commit | 6f9770137369e00bdad6fe9dcfe282cac4dd8c40 (patch) | |
tree | 0d6f5b9006b0e1c99bfbaf570aced08cc4670ab1 /src/misc1.c | |
parent | 70d60e9da1db6d916421b49347ead381e914aaad (diff) | |
download | vim-git-6f9770137369e00bdad6fe9dcfe282cac4dd8c40.tar.gz |
updated for version 7.2.326v7.2.326
Diffstat (limited to 'src/misc1.c')
-rw-r--r-- | src/misc1.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/misc1.c b/src/misc1.c index 3da0d9aef..6b6f33991 100644 --- a/src/misc1.c +++ b/src/misc1.c @@ -3470,7 +3470,9 @@ init_homedir() homedrive = mch_getenv((char_u *)"HOMEDRIVE"); homepath = mch_getenv((char_u *)"HOMEPATH"); - if (homedrive != NULL && homepath != NULL + if (homepath == NULL || *homepath == NUL) + homepath = "\\"; + if (homedrive != NULL && STRLEN(homedrive) + STRLEN(homepath) < MAXPATHL) { sprintf((char *)NameBuff, "%s%s", homedrive, homepath); |