diff options
author | Andrew Bartlett <abartlet@samba.org> | 2003-03-10 12:08:32 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2003-03-10 12:08:32 +0000 |
commit | 8cad904f385dfe25e6dffe39a773641d02ed2776 (patch) | |
tree | 4a1df9ffeb00e96e7c6a1ae89c485932e1de4af5 /source3 | |
parent | fba0a720353c113e7aedc6fb7e90f0aff938a8fb (diff) | |
download | samba-8cad904f385dfe25e6dffe39a773641d02ed2776.tar.gz samba-8cad904f385dfe25e6dffe39a773641d02ed2776.tar.bz2 samba-8cad904f385dfe25e6dffe39a773641d02ed2776.zip |
Don't segfault on make_server_info_guest() failure - instead return the
error code.
make_server_info_guest() requires an entry in the SAM at the moment, but
this will change before release.
Andrew Bartlett
(This used to be commit 6a956390fa253e87e38b3f1909f13595fbf2767a)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/sesssetup.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c index dfe246e398..2661fe3f93 100644 --- a/source3/smbd/sesssetup.c +++ b/source3/smbd/sesssetup.c @@ -39,16 +39,14 @@ static NTSTATUS do_map_to_guest(NTSTATUS status, auth_serversupplied_info **serv (lp_map_to_guest() == MAP_TO_GUEST_ON_BAD_PASSWORD)) { DEBUG(3,("No such user %s [%s] - using guest account\n", user, domain)); - make_server_info_guest(server_info); - status = NT_STATUS_OK; + status = make_server_info_guest(server_info); } } if (NT_STATUS_EQUAL(status, NT_STATUS_WRONG_PASSWORD)) { if (lp_map_to_guest() == MAP_TO_GUEST_ON_BAD_PASSWORD) { DEBUG(3,("Registered username %s for guest access\n",user)); - make_server_info_guest(server_info); - status = NT_STATUS_OK; + status = make_server_info_guest(server_info); } } |