Am 02.06.2011 17:07, schrieb Bram Moolenaar:
It's perfectly OK for homedir to be NULL.  Setting it to any random
directory is not a good idea.

You are perfectly right!

I have copied MSYS's vim.exe (and the dynamic libs it depends on) into a separate directory. In a cmd.exe shell, I chdir into this directory and "set HOME=" and "set PATH=". If I then start vim, it complains twice that it "Cannot execute shell sh" and that it "Cannot expand wildcards" and forces me to "Press ENTER" but then continues without further complaints.

If I leave both environment variables unset and I now copy MSYS's sh.exe (i.e. a hard link to bash.exe) into this directory, vim.exe crashes at start.

If I set HOME back to something reasonable, vim.exe starts successfully and merely complains that it cannot find its syntax.vim file (I have "syntax on" in my $HOME/.vimrc).

Where does Vim crash when homedir is NULL?  That should be fixed.

However, since vim starts without crashing when HOME is unset and sh.exe is *absent*, I think it's not an issue in vim.exe itself, but maybe in the way it invokes the shell. The sh.exe I just copied over from MSYS starts just fine even if HOME is unset...

 - Fabian

--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui