summaryrefslogtreecommitdiff
path: root/source3/auth/auth_winbind.c
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2003-05-27 16:46:51 +0000
committerGerald Carter <jerry@samba.org>2003-05-27 16:46:51 +0000
commit3a6d0a23cd226214778959d021a4a6d3eabc0c4b (patch)
tree41f864abdcc191f6c168cd026c2f0368af4ab389 /source3/auth/auth_winbind.c
parentcc841dde2f26843c2b6ec788337b779ed1abf8ea (diff)
downloadsamba-3a6d0a23cd226214778959d021a4a6d3eabc0c4b.tar.gz
samba-3a6d0a23cd226214778959d021a4a6d3eabc0c4b.tar.bz2
samba-3a6d0a23cd226214778959d021a4a6d3eabc0c4b.zip
volker's fix for crash when my_private_data == NULL
(This used to be commit 40127404e3a664539de516723cf1239f47adc442)
Diffstat (limited to 'source3/auth/auth_winbind.c')
-rw-r--r--source3/auth/auth_winbind.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/source3/auth/auth_winbind.c b/source3/auth/auth_winbind.c
index 79395a99c9..b8276b0866 100644
--- a/source3/auth/auth_winbind.c
+++ b/source3/auth/auth_winbind.c
@@ -103,9 +103,15 @@ static NTSTATUS check_winbind_security(const struct auth_context *auth_context,
result = winbindd_request(WINBINDD_PAM_AUTH_CRAP, &request, &response);
- if (result == NSS_STATUS_UNAVAIL) {
+ if ( result == NSS_STATUS_UNAVAIL ) {
struct auth_methods *auth_method = my_private_data;
- return auth_method->auth(auth_context, auth_method->private_data, mem_ctx, user_info, server_info);
+
+ if ( auth_method )
+ return auth_method->auth(auth_context, auth_method->private_data,
+ mem_ctx, user_info, server_info);
+ else
+ /* log an error since this should not happen */
+ DEBUG(0,("check_winbind_security: ERROR! my_private_data == NULL!\n"));
}
nt_status = NT_STATUS(response.data.auth.nt_status);