s3: replace some data_blob_talloc by data_blob_const
authorVolker Lendecke <vl@samba.org>
Tue, 20 Apr 2010 18:37:35 +0000 (20:37 +0200)
committerVolker Lendecke <vl@samba.org>
Fri, 23 Apr 2010 21:41:04 +0000 (23:41 +0200)
source3/winbindd/winbindd_pam.c

index ae7a3639245fd278c161d573188e368a64e8b855..334187ca7b876cc4102da9bf06f799da1d608875 100644 (file)
@@ -2186,24 +2186,20 @@ enum winbindd_result winbindd_dual_pam_chng_pswd_auth_crap(struct winbindd_domai
                  (unsigned long)state->pid, domain, user));
 
        /* Change password */
-       new_nt_password = data_blob_talloc(
-               state->mem_ctx,
+       new_nt_password = data_blob_const(
                state->request->data.chng_pswd_auth_crap.new_nt_pswd,
                state->request->data.chng_pswd_auth_crap.new_nt_pswd_len);
 
-       old_nt_hash_enc = data_blob_talloc(
-               state->mem_ctx,
+       old_nt_hash_enc = data_blob_const(
                state->request->data.chng_pswd_auth_crap.old_nt_hash_enc,
                state->request->data.chng_pswd_auth_crap.old_nt_hash_enc_len);
 
        if(state->request->data.chng_pswd_auth_crap.new_lm_pswd_len > 0)        {
-               new_lm_password = data_blob_talloc(
-                       state->mem_ctx,
+               new_lm_password = data_blob_const(
                        state->request->data.chng_pswd_auth_crap.new_lm_pswd,
                        state->request->data.chng_pswd_auth_crap.new_lm_pswd_len);
 
-               old_lm_hash_enc = data_blob_talloc(
-                       state->mem_ctx,
+               old_lm_hash_enc = data_blob_const(
                        state->request->data.chng_pswd_auth_crap.old_lm_hash_enc,
                        state->request->data.chng_pswd_auth_crap.old_lm_hash_enc_len);
        } else {