From cd559192633d78a9f06e239c6a448955f6ea0842 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Tue, 21 Feb 2006 14:34:11 +0000 Subject: r13590: * replace all pdb_init_sam[_talloc]() calls with samu_new() * replace all pdb_{init,fill}_sam_pw() calls with samu_set_unix() (This used to be commit 6f1afa4acc93a07d0ee9940822d7715acaae634f) --- source3/passdb/pdb_smbpasswd.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) (limited to 'source3/passdb/pdb_smbpasswd.c') diff --git a/source3/passdb/pdb_smbpasswd.c b/source3/passdb/pdb_smbpasswd.c index ebd5de2258..f354d0c444 100644 --- a/source3/passdb/pdb_smbpasswd.c +++ b/source3/passdb/pdb_smbpasswd.c @@ -1190,7 +1190,7 @@ static BOOL build_sam_account(struct smbpasswd_privates *smbpasswd_state, { struct passwd *pwfile; - if (sam_pass==NULL) { + if ( !sam_pass ) { DEBUG(5,("build_sam_account: struct samu is NULL\n")); return False; } @@ -1203,7 +1203,7 @@ static BOOL build_sam_account(struct smbpasswd_privates *smbpasswd_state, return False; } - if (!NT_STATUS_IS_OK(pdb_fill_sam_pw(sam_pass, pwfile))) + if ( !NT_STATUS_IS_OK( samu_set_unix(sam_pass, pwfile)) ) return False; TALLOC_FREE(pwfile); @@ -1269,13 +1269,11 @@ static NTSTATUS smbpasswd_getsampwent(struct pdb_methods *my_methods, struct sam struct smbpasswd_privates *smbpasswd_state = (struct smbpasswd_privates*)my_methods->private_data; struct smb_passwd *pw_buf=NULL; BOOL done = False; + DEBUG(5,("pdb_getsampwent\n")); - if (user==NULL) { + if ( !user ) { DEBUG(5,("pdb_getsampwent (smbpasswd): user is NULL\n")); -#if 0 - smb_panic("NULL pointer passed to getsampwent (smbpasswd)\n"); -#endif return nt_status; } @@ -1338,9 +1336,6 @@ static NTSTATUS smbpasswd_getsampwnam(struct pdb_methods *my_methods, if (!sam_acct) { DEBUG(10,("getsampwnam (smbpasswd): struct samu is NULL\n")); -#if 0 - smb_panic("NULL pointer passed to pdb_getsampwnam\n"); -#endif return nt_status; } @@ -1398,9 +1393,6 @@ static NTSTATUS smbpasswd_getsampwsid(struct pdb_methods *my_methods, struct sam if (!sam_acct) { DEBUG(10,("getsampwrid: (smbpasswd) struct samu is NULL\n")); -#if 0 - smb_panic("NULL pointer passed to pdb_getsampwrid\n"); -#endif return nt_status; } -- cgit