From 25795c3da920adba845367bf3394b5ba5912c1d5 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Fri, 12 May 2017 02:28:02 +0200 Subject: [PATCH] ldb: Force use of a private event context in ldb_tdb ldb_tdb holds locks while making callbacks, so force the use of a per-request event context Signed-off-by: Andrew Bartlett Reviewed-by: Stefan Metzmacher Reviewed-by: Garming Sam --- lib/ldb/ldb_tdb/ldb_tdb.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/ldb/ldb_tdb/ldb_tdb.c b/lib/ldb/ldb_tdb/ldb_tdb.c index 3dfd1ccf652..aed6044ab6f 100644 --- a/lib/ldb/ldb_tdb/ldb_tdb.c +++ b/lib/ldb/ldb_tdb/ldb_tdb.c @@ -1556,6 +1556,13 @@ static int ltdb_connect(struct ldb_context *ldb, const char *url, int tdb_flags, open_flags; struct ltdb_private *ltdb; + /* + * We hold locks, so we must use a private event context + * on each returned handle + */ + + ldb_set_require_private_event_context(ldb); + /* parse the url */ if (strchr(url, ':')) { if (strncmp(url, "tdb://", 6) != 0) { -- 2.47.2