]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: ntlm_auth: Use cmdline_messaging_context
authorChristof Schmitt <cs@samba.org>
Mon, 20 Aug 2018 23:18:20 +0000 (16:18 -0700)
committerAndreas Schneider <asn@cryptomilk.org>
Fri, 7 Sep 2018 15:26:16 +0000 (17:26 +0200)
Call cmdline_messaging_context to initialize the messaging context
before accessing clustered Samba config.

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>
source3/utils/ntlm_auth.c
source3/utils/wscript_build

index 7d27712980b298121e561b2de78aa3cfd5fe584b..b8014ec103465e9ba0d1ac3551662ba2e1f3b4be 100644 (file)
@@ -47,6 +47,7 @@
 #include "nsswitch/libwbclient/wbclient.h"
 #include "lib/param/loadparm.h"
 #include "lib/util/base64.h"
+#include "cmdline_contexts.h"
 
 #if HAVE_KRB5
 #include "auth/kerberos/pac_utils.h"
@@ -2380,6 +2381,8 @@ enum {
 
        poptFreeContext(pc);
 
+       cmdline_messaging_context(get_dyn_CONFIGFILE());
+
        if (!lp_load_global(get_dyn_CONFIGFILE())) {
                d_fprintf(stderr, "ntlm_auth: error opening config file %s. Error was %s\n",
                        get_dyn_CONFIGFILE(), strerror(errno));
index 7e586dc268d133f088a32c0e7d706001b659a3db..92404a61c2db612c0c2583f45ba236001f508546 100644 (file)
@@ -128,6 +128,7 @@ bld.SAMBA3_BINARY('ntlm_auth',
                  tiniparser
                  libsmb
                  popt_samba3
+                 cmdline_contexts
                  gse gensec''')
 
 bld.SAMBA3_BINARY('dbwrap_tool',