summaryrefslogtreecommitdiffstats
path: root/source/auth/auth_sam.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2002-01-15 01:14:58 +0000
committerAndrew Bartlett <abartlet@samba.org>2002-01-15 01:14:58 +0000
commit5b4079f748e25f21162e21b439063249baf8dca6 (patch)
tree8acf3482a8f30a7ae1172bee239d646fdbb29346 /source/auth/auth_sam.c
parent144345b41d39a6f68d01f62b7aee64ca0d328085 (diff)
downloadsamba-5b4079f748e25f21162e21b439063249baf8dca6.tar.gz
samba-5b4079f748e25f21162e21b439063249baf8dca6.tar.xz
samba-5b4079f748e25f21162e21b439063249baf8dca6.zip
Commit the auth associated changes I missed from the last commit.
Also set the default value of all the allocated strings to "" to avoid changing the interface (becouse pdb_get...() would point to a null string, rather than a null pointer and parts of samba rely on that). Andrew Bartlett
Diffstat (limited to 'source/auth/auth_sam.c')
-rw-r--r--source/auth/auth_sam.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/auth/auth_sam.c b/source/auth/auth_sam.c
index 107e33c6000..01f41fce441 100644
--- a/source/auth/auth_sam.c
+++ b/source/auth/auth_sam.c
@@ -353,8 +353,10 @@ static NTSTATUS check_sam_security(const struct auth_context *auth_context,
return NT_STATUS_UNSUCCESSFUL;
}
- if (!pdb_init_sam(&sampass)) {
- return NT_STATUS_NO_MEMORY;
+ /* Can't use the talloc version here, becouse the returned struct gets
+ kept on the server_info */
+ if (!NT_STATUS_IS_OK(nt_status = pdb_init_sam(&sampass))) {
+ return nt_status;
}
/* get the account information */