[Python-checkins] cpython (3.2): plug refleak
benjamin.peterson
python-checkins at python.org
Wed Nov 23 06:17:12 CET 2011
http://hg.python.org/cpython/rev/714b76882eb8
changeset: 73716:714b76882eb8
branch: 3.2
parent: 73711:80d491aaeed2
user: Benjamin Peterson <benjamin at python.org>
date: Tue Nov 22 23:12:49 2011 -0600
summary:
plug refleak
files:
Modules/posixmodule.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -6193,8 +6193,10 @@
s1 = PyBytes_AsString(os1);
err = unsetenv(s1);
- if (err)
+ if (err) {
+ Py_DECREF(s1);
return posix_error();
+ }
/* Remove the key from posix_putenv_garbage;
* this will cause it to be collected. This has to
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list