diff options
author | Jeremy Allison <jra@samba.org> | 2001-11-03 23:34:24 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-11-03 23:34:24 +0000 |
commit | f8e2baf39eb864481dd48f61404136b325cd73c2 (patch) | |
tree | 01e73e826f6f817e7ef9dd044cd1cc919eb152d1 /source3/libsmb/pwd_cache.c | |
parent | 69a59c5bbceb4ea5a766cf8e9a42392369142e91 (diff) | |
download | samba-f8e2baf39eb864481dd48f61404136b325cd73c2.tar.gz samba-f8e2baf39eb864481dd48f61404136b325cd73c2.tar.bz2 samba-f8e2baf39eb864481dd48f61404136b325cd73c2.zip |
Added NT_USER_TOKEN into server_info to fix extra groups problem.
Got "medieval on our ass" about const warnings (as many as I could :-).
Jeremy.
(This used to be commit ee5e7ca547eff016818ba5c43b8ea0c9fa69b808)
Diffstat (limited to 'source3/libsmb/pwd_cache.c')
-rw-r--r-- | source3/libsmb/pwd_cache.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/source3/libsmb/pwd_cache.c b/source3/libsmb/pwd_cache.c index 64e23e0feb..4a2c5f1604 100644 --- a/source3/libsmb/pwd_cache.c +++ b/source3/libsmb/pwd_cache.c @@ -49,41 +49,31 @@ BOOL pwd_is_nullpwd(const struct pwd_info *pwd) /**************************************************************************** compares two passwords. hmm, not as trivial as expected. hmm. ****************************************************************************/ -BOOL pwd_compare(struct pwd_info *pwd1, struct pwd_info *pwd2) +BOOL pwd_compare(const struct pwd_info *pwd1, const struct pwd_info *pwd2) { - if (pwd1->cleartext && pwd2->cleartext) - { + if (pwd1->cleartext && pwd2->cleartext) { if (strequal(pwd1->password, pwd2->password)) - { return True; - } } if (pwd1->null_pwd && pwd2->null_pwd) - { return True; - } if (!pwd1->null_pwd && !pwd2->null_pwd && - !pwd1->cleartext && !pwd2->cleartext) - { + !pwd1->cleartext && !pwd2->cleartext) { #ifdef DEBUG_PASSWORD DEBUG(100,("pwd compare: nt#\n")); dump_data(100, pwd1->smb_nt_pwd, 16); dump_data(100, pwd2->smb_nt_pwd, 16); #endif if (memcmp(pwd1->smb_nt_pwd, pwd2->smb_nt_pwd, 16) == 0) - { return True; - } #ifdef DEBUG_PASSWORD DEBUG(100,("pwd compare: lm#\n")); dump_data(100, pwd1->smb_lm_pwd, 16); dump_data(100, pwd2->smb_lm_pwd, 16); #endif if (memcmp(pwd1->smb_lm_pwd, pwd2->smb_lm_pwd, 16) == 0) - { return True; - } } return False; } |