diff options
author | Jean-François Micouleau <jfm@samba.org> | 2001-05-04 15:44:27 +0000 |
---|---|---|
committer | Jean-François Micouleau <jfm@samba.org> | 2001-05-04 15:44:27 +0000 |
commit | f35157f39293f9fa240a28642c41708b55d301c8 (patch) | |
tree | cd0eb02e9b316899d2cfb9b8cc2784ad739c60a5 /source3/smbd/lanman.c | |
parent | 1f7a451c1e059b5a86e1e78debd582579aa7bcb7 (diff) | |
download | samba-f35157f39293f9fa240a28642c41708b55d301c8.tar.gz samba-f35157f39293f9fa240a28642c41708b55d301c8.tar.xz samba-f35157f39293f9fa240a28642c41708b55d301c8.zip |
Big cleanup of passdb and backends.
I did some basic tests but I have probably broken something. Notably the
password changing. So don't cry ;-)
J.F.
(This used to be commit a4a4c02b12f030a3b9e6225b999c90689dfc4719)
Diffstat (limited to 'source3/smbd/lanman.c')
-rw-r--r-- | source3/smbd/lanman.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 8dc3d8308a2..d5dd8766702 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -1765,7 +1765,7 @@ static BOOL api_SetUserPassword(connection_struct *conn,uint16 vuid, char *param { fstring saved_pass2; - SAM_ACCOUNT *sampass; + SAM_ACCOUNT *sampass=NULL; /* * Save the new password as change_oem_password overwrites it @@ -1788,7 +1788,9 @@ static BOOL api_SetUserPassword(connection_struct *conn,uint16 vuid, char *param if(lp_unix_password_sync() && !chgpasswd(user,pass1,saved_pass2,False)) SSVAL(*rparam,0,NERR_badpass); } - } + pdb_clear_sam(sampass); + } + /* * If the above failed, attempt the plaintext password change. @@ -1823,8 +1825,10 @@ static BOOL api_SetUserPassword(connection_struct *conn,uint16 vuid, char *param { SSVAL(*rparam,0,NERR_Success); } + pdb_clear_sam(hnd); } + memset((char *)pass1,'\0',sizeof(fstring)); memset((char *)pass2,'\0',sizeof(fstring)); |