Nikola Knezevic wrote:

> > Hi,
> > 
> > there is a problem with MacVim when using zsh as default shell. The
> > problem occurs in VCSCommand plugin, when it spawns git process trying
> > to detect vcs-related info. These processes just hang, and wait. I
> > described it at [1]. Bjorn pointed me to the implementation of
> > macosx_fork in os_macosx.m, as the most likely culprit. After some
> > looking, I decided to implement double-fork trick, to completely
> > detach Vim from the terminal, which did the trick. However, I still
> > don't know what is the actual reason for sub-processes hanging.
> > 
> > My question is: what are the requirements for the fork()-ed instance
> > of Vim? Should it have access to the controlling terminal, or not? I'm
> > trying to understand if there are any problems with using double-fork
> > with vim.
> > 
> > [1] 
> > http://groups.google.com/group/vim_mac/browse_thread/thread/78b18ce8cc15557d
> 
> Hi,
> 
> I managed to trace the problem to PTY handling on Mac OS X. It was not
> a problem of setsid, but the order of closing file descriptors. Also,
> I reverted the double-forking patch, as it was not the right solution.
> 
>  I'm including the patch, which holds the explanation of the problem.
>  Bjorn has already applied this patch to MacVim.
> 
> Can you please have a look at it?

Would keeping the slave side fd open cause problems on any other system?
I can't think of a reason, but you never know.

-- 
Fingers not found - Pound head on keyboard to continue.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
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