s4:auth: avoid str_list related const warnings
authorStefan Metzmacher <metze@samba.org>
Wed, 26 Feb 2014 19:16:26 +0000 (20:16 +0100)
committerStefan Metzmacher <metze@samba.org>
Wed, 12 Mar 2014 22:39:48 +0000 (23:39 +0100)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
source4/auth/ntlm/auth.c
source4/auth/sam.c

index ccfd20ad05f7cd259c5144d73ca88191f391528a..16c9666c0a214601f33d412df6a2e81cad8f9fcf 100644 (file)
@@ -596,7 +596,7 @@ const char **auth_methods_from_lp(TALLOC_CTX *mem_ctx, struct loadparm_context *
                auth_methods = str_list_make(mem_ctx, "anonymous sam_ignoredomain winbind", NULL);
                break;
        }
-       return (const char **) auth_methods;
+       return discard_const_p(const char *, auth_methods);
 }
 
 /***************************************************************************
index ac1986230aac376c5a57116fd0c14ced13ca92dc..72c57b92c81b5300d173e60ac0683340c0c6085d 100644 (file)
@@ -221,8 +221,8 @@ _PUBLIC_ NTSTATUS authsam_account_ok(TALLOC_CTX *mem_ctx,
        if (logon_workstation && workstation_list && *workstation_list) {
                bool invalid_ws = true;
                int i;
-               const char **workstations = (const char **)str_list_make(mem_ctx, workstation_list, ",");
-               
+               char **workstations = str_list_make(mem_ctx, workstation_list, ",");
+
                for (i = 0; workstations && workstations[i]; i++) {
                        DEBUG(10,("sam_account_ok: checking for workstation match '%s' and '%s'\n",
                                  workstations[i], logon_workstation));