#include "system/filesys.h"
#include "tdb_wrap.h"
#include "lib/ldb/include/ldb.h"
-#include "lib/tdb/include/tdb.h"
-#include "lib/util/util_tdb.h"
-#include "lib/util/util_ldb.h"
+#include "../tdb/include/tdb.h"
+#include "../lib/util/util_tdb.h"
+#include "../lib/util/util_ldb.h"
#include "librpc/gen_ndr/ndr_security.h"
/**
/**
connect to the secrets ldb
*/
-struct ldb_context *secrets_db_connect(TALLOC_CTX *mem_ctx, struct loadparm_context *lp_ctx)
+struct ldb_context *secrets_db_connect(TALLOC_CTX *mem_ctx,
+ struct event_context *ev_ctx,
+ struct loadparm_context *lp_ctx)
{
char *path;
const char *url;
/* Secrets.ldb *must* always be local. If we call for a
* system_session() we will recurse */
- ldb = ldb_init(mem_ctx);
+ ldb = ldb_init(mem_ctx, ev_ctx);
if (!ldb) {
talloc_free(path);
return NULL;
* @return pointer to a SID object if the SID could be obtained, NULL otherwise
*/
struct dom_sid *secrets_get_domain_sid(TALLOC_CTX *mem_ctx,
+ struct event_context *ev_ctx,
struct loadparm_context *lp_ctx,
const char *domain)
{
const struct ldb_val *v;
enum ndr_err_code ndr_err;
- ldb = secrets_db_connect(mem_ctx, lp_ctx);
+ ldb = secrets_db_connect(mem_ctx, ev_ctx, lp_ctx);
if (ldb == NULL) {
DEBUG(5, ("secrets_db_connect failed\n"));
return NULL;