summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2007-12-03 21:25:06 +0100
committerStefan Metzmacher <metze@samba.org>2007-12-21 05:47:42 +0100
commit2f8dc4f48f1802baa3405e7803563f6840e0d1b3 (patch)
treea479c7df067cb698134616bc6be8fa2fd76c7452 /source4/lib
parentc9f0011bc57e6536f4ec130784d15609e71aa694 (diff)
downloadsamba-2f8dc4f48f1802baa3405e7803563f6840e0d1b3.tar.gz
samba-2f8dc4f48f1802baa3405e7803563f6840e0d1b3.tar.bz2
samba-2f8dc4f48f1802baa3405e7803563f6840e0d1b3.zip
r26266: Remove more global_loadparm uses.
(This used to be commit 99113075c4a96679bcec4f4d6bba4acb3dee4245)
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/events/events.c5
-rw-r--r--source4/lib/messaging/tests/irpc.c4
-rw-r--r--source4/lib/messaging/tests/messaging.c13
-rw-r--r--source4/lib/util/util_ldb.h55
4 files changed, 8 insertions, 69 deletions
diff --git a/source4/lib/events/events.c b/source4/lib/events/events.c
index 2b36c92491..fd736e46d8 100644
--- a/source4/lib/events/events.c
+++ b/source4/lib/events/events.c
@@ -183,11 +183,6 @@ struct event_context *event_context_init_byname(TALLOC_CTX *mem_ctx, const char
event_backend_init();
-#if _SAMBA_BUILD_
- if (name == NULL) {
- name = lp_parm_string(global_loadparm, NULL, "event", "backend");
- }
-#endif
if (name == NULL) {
name = event_default_backend;
}
diff --git a/source4/lib/messaging/tests/irpc.c b/source4/lib/messaging/tests/irpc.c
index aae6b4882e..28676c21c7 100644
--- a/source4/lib/messaging/tests/irpc.c
+++ b/source4/lib/messaging/tests/irpc.c
@@ -215,12 +215,12 @@ static bool irpc_setup(struct torture_context *tctx, void **_data)
*_data = data = talloc(tctx, struct irpc_test_data);
- lp_set_cmdline(global_loadparm, "pid directory", "piddir.tmp");
+ lp_set_cmdline(tctx->lp_ctx, "pid directory", "piddir.tmp");
data->ev = tctx->ev;
torture_assert(tctx, data->msg_ctx1 =
messaging_init(tctx,
- lp_messaging_path(tctx, global_loadparm),
+ lp_messaging_path(tctx, tctx->lp_ctx),
cluster_id(MSG_ID1), data->ev),
"Failed to init first messaging context");
diff --git a/source4/lib/messaging/tests/messaging.c b/source4/lib/messaging/tests/messaging.c
index bf2b83a0e4..ba3d2f91d6 100644
--- a/source4/lib/messaging/tests/messaging.c
+++ b/source4/lib/messaging/tests/messaging.c
@@ -66,23 +66,22 @@ static bool test_ping_speed(struct torture_context *tctx)
struct timeval tv;
int timelimit = torture_setting_int(tctx, "timelimit", 10);
uint32_t msg_ping, msg_exit;
- TALLOC_CTX *mem_ctx = tctx;
- lp_set_cmdline(global_loadparm, "pid directory", "piddir.tmp");
+ lp_set_cmdline(tctx->lp_ctx, "pid directory", "piddir.tmp");
ev = tctx->ev;
- msg_server_ctx = messaging_init(mem_ctx,
- lp_messaging_path(tctx, global_loadparm),
+ msg_server_ctx = messaging_init(tctx,
+ lp_messaging_path(tctx, tctx->lp_ctx),
cluster_id(1), ev);
torture_assert(tctx, msg_server_ctx != NULL, "Failed to init ping messaging context");
messaging_register_tmp(msg_server_ctx, NULL, ping_message, &msg_ping);
- messaging_register_tmp(msg_server_ctx, mem_ctx, exit_message, &msg_exit);
+ messaging_register_tmp(msg_server_ctx, tctx, exit_message, &msg_exit);
- msg_client_ctx = messaging_init(mem_ctx,
- lp_messaging_path(mem_ctx, global_loadparm),
+ msg_client_ctx = messaging_init(tctx,
+ lp_messaging_path(tctx, tctx->lp_ctx),
cluster_id(2), ev);
torture_assert(tctx, msg_client_ctx != NULL,
diff --git a/source4/lib/util/util_ldb.h b/source4/lib/util/util_ldb.h
deleted file mode 100644
index f4f56d6b18..0000000000
--- a/source4/lib/util/util_ldb.h
+++ /dev/null
@@ -1,55 +0,0 @@
-#ifndef __LIB_UTIL_UTIL_LDB_H__
-#define __LIB_UTIL_UTIL_LDB_H__
-
-#undef _PRINTF_ATTRIBUTE
-#define _PRINTF_ATTRIBUTE(a1, a2) PRINTF_ATTRIBUTE(a1, a2)
-/* This file was automatically generated by mkproto.pl. DO NOT EDIT */
-
-#ifndef _PUBLIC_
-#define _PUBLIC_
-#endif
-
-#ifndef _PURE_
-#define _PURE_
-#endif
-
-#ifndef _NORETURN_
-#define _NORETURN_
-#endif
-
-#ifndef _DEPRECATED_
-#define _DEPRECATED_
-#endif
-
-#ifndef _WARN_UNUSED_RESULT_
-#define _WARN_UNUSED_RESULT_
-#endif
-
-
-/* The following definitions come from lib/util/util_ldb.c */
-
-int gendb_search_v(struct ldb_context *ldb,
- TALLOC_CTX *mem_ctx,
- struct ldb_dn *basedn,
- struct ldb_message ***msgs,
- const char * const *attrs,
- const char *format,
- va_list ap) _PRINTF_ATTRIBUTE(6,0);
-int gendb_search(struct ldb_context *ldb,
- TALLOC_CTX *mem_ctx,
- struct ldb_dn *basedn,
- struct ldb_message ***res,
- const char * const *attrs,
- const char *format, ...) _PRINTF_ATTRIBUTE(6,7);
-int gendb_search_dn(struct ldb_context *ldb,
- TALLOC_CTX *mem_ctx,
- struct ldb_dn *dn,
- struct ldb_message ***res,
- const char * const *attrs);
-int gendb_add_ldif(struct ldb_context *ldb, const char *ldif_string);
-char *wrap_casefold(void *context, void *mem_ctx, const char *s);
-#undef _PRINTF_ATTRIBUTE
-#define _PRINTF_ATTRIBUTE(a1, a2)
-
-#endif /* __LIB_UTIL_UTIL_LDB_H__ */
-