From ff5910e14190d0667bba345ed78b27bece36dee2 Mon Sep 17 00:00:00 2001 From: Hiroshi Inoue Date: Sat, 16 Feb 2013 12:58:00 +0000 Subject: [PATCH] Protect shared connection list when making cleanup tasks in EN_Destructor using the patch provided by Michael Kocherov. --- environ.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/environ.c b/environ.c index 87e25d0..8a24293 100644 --- a/environ.c +++ b/environ.c @@ -583,6 +583,7 @@ EN_Destructor(EnvironmentClass *self) */ /* Free any connections belonging to this environment */ + ENTER_CONNS_CS; for (lf = 0, nullcnt = 0; lf < conns_count; lf++) { if (NULL == conns[lf]) @@ -603,6 +604,7 @@ EN_Destructor(EnvironmentClass *self) conns = NULL; conns_count = 0; } + LEAVE_CONNS_CS; DELETE_ENV_CS(self); free(self); -- 2.39.5