s3: Remove "mem_ctx" from a few functions
authorVolker Lendecke <vl@samba.org>
Thu, 9 Sep 2010 02:12:21 +0000 (19:12 -0700)
committerVolker Lendecke <vl@samba.org>
Thu, 9 Sep 2010 04:19:25 +0000 (06:19 +0200)
source3/winbindd/winbindd_creds.c
source3/winbindd/winbindd_pam.c
source3/winbindd/winbindd_proto.h

index 174eba4f4d438e1434cf8058ea15e37cd281188c..b1910b62c98240699db72e26faedd151f1262cb3 100644 (file)
@@ -54,7 +54,6 @@ NTSTATUS winbindd_get_creds(struct winbindd_domain *domain,
 
 
 NTSTATUS winbindd_store_creds(struct winbindd_domain *domain,
-                             TALLOC_CTX *mem_ctx, 
                              const char *user, 
                              const char *pass, 
                              struct netr_SamInfo3 *info3)
@@ -128,20 +127,18 @@ NTSTATUS winbindd_store_creds(struct winbindd_domain *domain,
 }
 
 NTSTATUS winbindd_update_creds_by_info3(struct winbindd_domain *domain,
-                                       TALLOC_CTX *mem_ctx,
                                        const char *user,
                                        const char *pass,
                                        struct netr_SamInfo3 *info3)
 {
-       return winbindd_store_creds(domain, mem_ctx, user, pass, info3);
+       return winbindd_store_creds(domain, user, pass, info3);
 }
 
 NTSTATUS winbindd_update_creds_by_name(struct winbindd_domain *domain,
-                                      TALLOC_CTX *mem_ctx,
                                       const char *user,
                                       const char *pass)
 {
-       return winbindd_store_creds(domain, mem_ctx, user, pass, NULL);
+       return winbindd_store_creds(domain, user, pass, NULL);
 }
 
 
index c162cc6feb6a48e6ae558225a13f2eee865a99dd..e71e152d448168d52a4f9114c652449d888906ce 100644 (file)
@@ -1004,7 +1004,6 @@ static NTSTATUS winbindd_dual_pam_auth_cached(struct winbindd_domain *domain,
                my_info3->base.bad_password_count = 0;
 
                result = winbindd_update_creds_by_info3(domain,
-                                                       state->mem_ctx,
                                                        state->request->data.auth.user,
                                                        state->request->data.auth.pass,
                                                        my_info3);
@@ -1052,7 +1051,6 @@ static NTSTATUS winbindd_dual_pam_auth_cached(struct winbindd_domain *domain,
 
 failed:
        result = winbindd_update_creds_by_info3(domain,
-                                               state->mem_ctx,
                                                state->request->data.auth.user,
                                                NULL,
                                                my_info3);
@@ -1615,7 +1613,6 @@ process_result:
                    && lp_winbind_offline_logon()) {
 
                        result = winbindd_store_creds(domain,
-                                                     state->mem_ctx,
                                                      state->request->data.auth.user,
                                                      state->request->data.auth.pass,
                                                      info3);
@@ -1933,8 +1930,7 @@ done:
        if (NT_STATUS_IS_OK(result) && (state->request->flags & WBFLAG_PAM_CACHED_LOGIN)) {
                if (lp_winbind_offline_logon()) {
                        result = winbindd_update_creds_by_name(contact_domain,
-                                                        state->mem_ctx, user,
-                                                        newpass);
+                                                              user, newpass);
                        /* Again, this happens when we login from gdm or xdm
                         * and the password expires, *BUT* cached crendentials
                         * doesn't exist. winbindd_update_creds_by_name()
index 60fb647c93ae99a3d76ab08bbae52f7204878160..7d36be1e17bec2934f4d92335ad72b9a8a172c49 100644 (file)
@@ -229,17 +229,14 @@ NTSTATUS winbindd_get_creds(struct winbindd_domain *domain,
                            const uint8 *cached_nt_pass[NT_HASH_LEN],
                            const uint8 *cred_salt[NT_HASH_LEN]);
 NTSTATUS winbindd_store_creds(struct winbindd_domain *domain,
-                             TALLOC_CTX *mem_ctx, 
                              const char *user, 
                              const char *pass, 
                              struct netr_SamInfo3 *info3);
 NTSTATUS winbindd_update_creds_by_info3(struct winbindd_domain *domain,
-                                       TALLOC_CTX *mem_ctx,
                                        const char *user,
                                        const char *pass,
                                        struct netr_SamInfo3 *info3);
 NTSTATUS winbindd_update_creds_by_name(struct winbindd_domain *domain,
-                                      TALLOC_CTX *mem_ctx,
                                       const char *user,
                                       const char *pass);