From 19030a08fbfb8596a2a3db55737828b08b378cd4 Mon Sep 17 00:00:00 2001 From: Neil Schemenauer Date: Tue, 16 Jan 2001 04:27:47 +0000 Subject: [PATCH] Plug memory leak. --- Modules/posixmodule.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c index b57bc02e6f63..99e5864b2c7d 100644 --- a/Modules/posixmodule.c +++ b/Modules/posixmodule.c @@ -5578,6 +5578,7 @@ INITFUNC(void) PyDict_SetItemString(d, "error", PyExc_OSError); #ifdef HAVE_PUTENV - posix_putenv_garbage = PyDict_New(); + if (posix_putenv_garbage == NULL) + posix_putenv_garbage = PyDict_New(); #endif }