Mercurial > public > mercurial-scm > python-hglib
comparison hglib/client.py @ 62:d1f57f162274
closefds on posix when using subprocess
see added test for a clarification on why this is needed
author | Idan Kamara <idankk86@gmail.com> |
---|---|
date | Fri, 19 Aug 2011 22:24:14 +0300 |
parents | d0b9215180a4 |
children | 939d1d763bb1 |
comparison
equal
deleted
inserted
replaced
61:d0b9215180a4 | 62:d1f57f162274 |
---|---|
22 env = dict(os.environ) | 22 env = dict(os.environ) |
23 if encoding: | 23 if encoding: |
24 env['HGENCODING'] = encoding | 24 env['HGENCODING'] = encoding |
25 | 25 |
26 self.server = subprocess.Popen(args, stdin=subprocess.PIPE, | 26 self.server = subprocess.Popen(args, stdin=subprocess.PIPE, |
27 stdout=subprocess.PIPE, env=env) | 27 stdout=subprocess.PIPE, env=env, |
28 close_fds=util.closefds) | |
28 | 29 |
29 self._readhello() | 30 self._readhello() |
30 self._version = None | 31 self._version = None |
31 | 32 |
32 def _readhello(self): | 33 def _readhello(self): |