URL: https://github.com/SSSD/sssd/pull/444
Author: fidencio
 Title: #444: NSS: Use netgr as memory context in set_netgr_lifetime() - Patch 
for SSSD-1.14
Action: synchronized

To pull the PR as Git branch:
git remote add ghsssd https://github.com/SSSD/sssd
git fetch ghsssd pull/444/head:pr444
git checkout pr444
From f38e83a5a939dee974a0e2855eb2a77a67255ba4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Fabiano=20Fid=C3=AAncio?= <[email protected]>
Date: Mon, 6 Nov 2017 17:13:14 +0100
Subject: [PATCH] NSS: Use nss_ctx as memory context in set_netgr_lifetime()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

We've noticed some crashes that happened because gctx is already freed,
but the timeout handler is still called. In order to avoid that, let's
remove the timeout handler when nss_ctx is freed at other places.

Resolves: https://pagure.io/SSSD/sssd/issue/3523

Signed-off-by: Fabiano FidĂȘncio <[email protected]>
---
 src/responder/nss/nsssrv_netgroup.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/responder/nss/nsssrv_netgroup.c b/src/responder/nss/nsssrv_netgroup.c
index 49ef0f5c9..c384cebd8 100644
--- a/src/responder/nss/nsssrv_netgroup.c
+++ b/src/responder/nss/nsssrv_netgroup.c
@@ -428,7 +428,7 @@ static void set_netgr_lifetime(uint32_t lifetime,
 
     tv = tevent_timeval_current_ofs(lifetime, 0);
     te = tevent_add_timer(step_ctx->nctx->rctx->ev,
-                          step_ctx->nctx->gctx, tv,
+                          step_ctx->nctx, tv,
                           setnetgrent_result_timeout,
                           netgr);
     if (!te) {
_______________________________________________
sssd-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to