summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
Diffstat (limited to 'source4')
-rw-r--r--source4/nbt_server/wins/winsdb.c12
-rw-r--r--source4/ntptr/simple_ldb/ntptr_simple_ldb.c2
-rw-r--r--source4/wrepl_server/wrepl_server.c2
3 files changed, 10 insertions, 6 deletions
diff --git a/source4/nbt_server/wins/winsdb.c b/source4/nbt_server/wins/winsdb.c
index 6727445437..18c1b725be 100644
--- a/source4/nbt_server/wins/winsdb.c
+++ b/source4/nbt_server/wins/winsdb.c
@@ -929,7 +929,8 @@ failed:
}
static bool winsdb_check_or_add_module_list(struct tevent_context *ev_ctx,
- struct loadparm_context *lp_ctx, struct winsdb_handle *h)
+ struct loadparm_context *lp_ctx, struct winsdb_handle *h,
+ const char *wins_path)
{
int trans;
int ret;
@@ -975,7 +976,7 @@ static bool winsdb_check_or_add_module_list(struct tevent_context *ev_ctx,
flags |= LDB_FLG_NOSYNC;
}
- h->ldb = ldb_wrap_connect(h, ev_ctx, lp_ctx, lpcfg_state_path(h, lp_ctx, lpcfg_wins_url(lp_ctx)),
+ h->ldb = ldb_wrap_connect(h, ev_ctx, lp_ctx, wins_path,
NULL, NULL, flags);
if (!h->ldb) goto failed;
@@ -1003,15 +1004,18 @@ struct winsdb_handle *winsdb_connect(TALLOC_CTX *mem_ctx,
unsigned int flags = 0;
bool ret;
int ldb_err;
+ char *wins_path;
h = talloc_zero(mem_ctx, struct winsdb_handle);
if (!h) return NULL;
+ wins_path = lpcfg_state_path(h, lp_ctx, "wins.ldb");
+
if (lpcfg_parm_bool(lp_ctx, NULL,"winsdb", "nosync", false)) {
flags |= LDB_FLG_NOSYNC;
}
- h->ldb = ldb_wrap_connect(h, ev_ctx, lp_ctx, lpcfg_lock_path(h, lp_ctx, lpcfg_wins_url(lp_ctx)),
+ h->ldb = ldb_wrap_connect(h, ev_ctx, lp_ctx, wins_path,
NULL, NULL, flags);
if (!h->ldb) goto failed;
@@ -1022,7 +1026,7 @@ struct winsdb_handle *winsdb_connect(TALLOC_CTX *mem_ctx,
if (!h->local_owner) goto failed;
/* make sure the module list is available and used */
- ret = winsdb_check_or_add_module_list(ev_ctx, lp_ctx, h);
+ ret = winsdb_check_or_add_module_list(ev_ctx, lp_ctx, h, wins_path);
if (!ret) goto failed;
ldb_err = ldb_set_opaque(h->ldb, "winsdb_handle", h);
diff --git a/source4/ntptr/simple_ldb/ntptr_simple_ldb.c b/source4/ntptr/simple_ldb/ntptr_simple_ldb.c
index c25c61d36b..04e3806853 100644
--- a/source4/ntptr/simple_ldb/ntptr_simple_ldb.c
+++ b/source4/ntptr/simple_ldb/ntptr_simple_ldb.c
@@ -48,7 +48,7 @@ NTSTATUS ntptr_simple_ldb_init(void);
*/
static struct ldb_context *sptr_db_connect(TALLOC_CTX *mem_ctx, struct tevent_context *ev_ctx, struct loadparm_context *lp_ctx)
{
- return ldb_wrap_connect(mem_ctx, ev_ctx, lp_ctx, lpcfg_spoolss_url(lp_ctx), system_session(lp_ctx),
+ return ldb_wrap_connect(mem_ctx, ev_ctx, lp_ctx, "spoolss.ldb", system_session(lp_ctx),
NULL, 0);
}
diff --git a/source4/wrepl_server/wrepl_server.c b/source4/wrepl_server/wrepl_server.c
index 064e11472c..e28afc6fe5 100644
--- a/source4/wrepl_server/wrepl_server.c
+++ b/source4/wrepl_server/wrepl_server.c
@@ -39,7 +39,7 @@ static struct ldb_context *wins_config_db_connect(TALLOC_CTX *mem_ctx,
struct loadparm_context *lp_ctx)
{
return ldb_wrap_connect(mem_ctx, ev_ctx, lp_ctx, lpcfg_private_path(mem_ctx,
- lp_ctx, lpcfg_wins_config_url(lp_ctx)),
+ lp_ctx, "wins_config.ldb"),
system_session(lp_ctx), NULL, 0);
}