From: Avery Pennarun Date: Thu, 15 Jul 2010 23:15:06 +0000 (-0400) Subject: git.py: use close_fds=True when starting git cat-file. X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=12e16e4ff446d607abdb1e633f0509620386e325;p=packages%2Fb%2Fbup.git git.py: use close_fds=True when starting git cat-file. Otherwise git could inherit some other file descriptors we're using. This is particularly relevant in cmd/web, and particularly when applying pmccurdy's patches to use Tornado. Signed-off-by: Avery Pennarun --- diff --git a/lib/bup/git.py b/lib/bup/git.py index d9f1944..e1482e6 100644 --- a/lib/bup/git.py +++ b/lib/bup/git.py @@ -792,6 +792,7 @@ class CatPipe: self.p = subprocess.Popen(['git', 'cat-file', '--batch'], stdin=subprocess.PIPE, stdout=subprocess.PIPE, + close_fds = True, preexec_fn = _gitenv) def _fast_get(self, id):