diff options
author | Garming Sam <garming@catalyst.net.nz> | 2014-03-27 08:51:56 +1300 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2014-07-31 08:17:11 +0200 |
commit | 26a6f05f0fe78579baec30d9f8afda923bc35ff0 (patch) | |
tree | 994d40527ec2f7d932550ec2e4f7dedf1e6e002e /source3/param | |
parent | 6f9a0b81356ad1abad03d8c00ee17c7cf0d6981d (diff) | |
download | samba-26a6f05f0fe78579baec30d9f8afda923bc35ff0.tar.gz samba-26a6f05f0fe78579baec30d9f8afda923bc35ff0.tar.xz samba-26a6f05f0fe78579baec30d9f8afda923bc35ff0.zip |
param: use lpcfg_dump_globals in s3 loadparm
Change-Id: I7f7f5238a47e0c3634757b74f3f852ce36988614
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3/param')
-rw-r--r-- | source3/param/loadparm.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index 547acf8e32..5c1c4fdf35 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -4064,11 +4064,22 @@ Display the contents of the services array in human-readable form. void lp_dump(FILE *f, bool show_defaults, int maxtoprint) { int iService; + struct loadparm_context *lp_ctx; if (show_defaults) defaults_saved = false; - dump_globals(f, defaults_saved); + lp_ctx = loadparm_init_s3(talloc_tos(), + loadparm_s3_helpers()); + if (lp_ctx == NULL) { + DEBUG(0, ("loadparm_init_s3 failed\n")); + return; + } + + lp_ctx->sDefault = &sDefault; + lp_ctx->services = ServicePtrs; + + lpcfg_dump_globals(lp_ctx, f, !defaults_saved); lpcfg_dump_a_service(&sDefault, &sDefault, f, flags_list, show_defaults); |