From 15136b3669e3ac59445fa7543be78a99997f9bdb Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Sat, 21 Apr 2007 20:35:49 +0000 Subject: [PATCH] Bug #1704790: bind name "sys" locally in __del__ method so that it is not cleared before __del__ is run. (backport from rev. 54918) --- Lib/subprocess.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/subprocess.py b/Lib/subprocess.py index aeca23d1a5d..ee9b4a2082f 100644 --- a/Lib/subprocess.py +++ b/Lib/subprocess.py @@ -628,7 +628,7 @@ class Popen(object): return data - def __del__(self): + def __del__(self, sys=sys): if not self._child_created: # We didn't get to successfully create a child process. return