Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d83f6e8

Browse files
committed
Make sure we ignore WindowsErrors too, in case the process is already dead
Fixes gitpython-developers#140
1 parent a4b8e46 commit d83f6e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git/cmd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def __del__(self):
103103
try:
104104
os.kill(self.proc.pid, 2) # interrupt signal
105105
self.proc.wait() # ensure process goes away
106-
except OSError:
106+
except (OSError, WindowsError):
107107
pass # ignore error when process already died
108108
except AttributeError:
109109
# try windows

0 commit comments

Comments
 (0)