1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-11 05:18:09 +03:00

s3:dbwrap_tool: Use cmdline_messaging_context

Initialize the messaging context through cmdline_messaging_context to
allow access to config in clustered Samba.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13465

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
Christof Schmitt 2018-08-21 12:34:34 -07:00 committed by Andreas Schneider
parent 095123df94
commit 7eeff96b82
2 changed files with 6 additions and 1 deletions

View File

@ -27,6 +27,7 @@
#include "dbwrap/dbwrap_open.h"
#include "messages.h"
#include "util_tdb.h"
#include "cmdline_contexts.h"
enum dbwrap_op { OP_FETCH, OP_STORE, OP_DELETE, OP_ERASE, OP_LISTKEYS,
OP_EXISTS };
@ -421,6 +422,8 @@ int main(int argc, const char **argv)
while (extra_argv[extra_argc]) extra_argc++;
}
cmdline_messaging_context(get_dyn_CONFIGFILE());
lp_load_global(get_dyn_CONFIGFILE());
if ((extra_argc < 2) || (extra_argc > 5)) {

View File

@ -136,7 +136,9 @@ bld.SAMBA3_BINARY('dbwrap_tool',
source='dbwrap_tool.c',
deps='''
talloc
popt_samba3''')
popt_samba3
cmdline_contexts
''')
bld.SAMBA3_BINARY('dbwrap_torture',
source='dbwrap_torture.c',