summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_util.c
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1998-09-24 20:02:56 +0000
committerLuke Leighton <lkcl@samba.org>1998-09-24 20:02:56 +0000
commitf650b65800c6d6c09cc2d59d7afe728fcb819a5f (patch)
tree11db7b86fe69a29e00f2aa22ec6aa9fd84bf4ddd /source3/rpc_server/srv_util.c
parent50beafdf22e54399af4b3dd841c53bfd6dd6de33 (diff)
downloadsamba-f650b65800c6d6c09cc2d59d7afe728fcb819a5f.tar.gz
samba-f650b65800c6d6c09cc2d59d7afe728fcb819a5f.tar.bz2
samba-f650b65800c6d6c09cc2d59d7afe728fcb819a5f.zip
this fixes the last of the issues where USRMGR.EXE and SRVMGR.EXE were
failing. running these two programs on a samba pdc now work. parse_samr.c: - removed __LINE__ from debug macros. - removed call to SMB_ASSERT_ARRAY() in samr_r_query_usergroups. the DOM_GID array is a malloc'd array (by make_dom_gids) not a static array. srv_samr.c: - replaced all "struct smb_passwd"s with sam_passwds instead. there were uid to rid confusion issues (assumptions that uids were equal to rids). - #if 0'd the pdb_rid_is_user() call which, given the above corrections, would probably work now. srv_util.c: - replaced "struct smb_passwd" with sam_passwd in lookup_user_rid, as assumptions were being made that uids were equal to rids. (This used to be commit 3f98697cd5203fba07518d7c777ba19644e35b45)
Diffstat (limited to 'source3/rpc_server/srv_util.c')
-rw-r--r--source3/rpc_server/srv_util.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/source3/rpc_server/srv_util.c b/source3/rpc_server/srv_util.c
index 68a4f79f0b..3c0fc9271e 100644
--- a/source3/rpc_server/srv_util.c
+++ b/source3/rpc_server/srv_util.c
@@ -478,18 +478,17 @@ uint32 lookup_alias_rid(char *alias_name, uint32 *rid)
********************************************************************/
uint32 lookup_user_rid(char *user_name, uint32 *rid)
{
- struct smb_passwd *smb_pass;
+ struct sam_passwd *sam_pass;
(*rid) = 0;
/* find the user account */
become_root(True);
- smb_pass = getsmbpwnam(user_name);
+ sam_pass = getsam21pwnam(user_name);
unbecome_root(True);
- if (smb_pass != NULL)
+ if (sam_pass != NULL)
{
- /* lkclXXXX SHOULD use name_to_rid() here! */
- (*rid) = smb_pass->smb_userid;
+ (*rid) = sam_pass->user_rid;
return 0x0;
}