diff --git a/source/smbd/password.c b/source/smbd/password.c index d15970cbefe..72292de4227 100644 --- a/source/smbd/password.c +++ b/source/smbd/password.c @@ -488,7 +488,11 @@ BOOL authorise_login(int snum, fstring user, DATA_BLOB password, /* now check the list of session users */ if (!ok) { char *auser; - char *user_list = strdup(session_userlist); + char *user_list = NULL; + + if ( session_userlist ) + user_list = strdup(session_userlist); + if (!user_list) return(False);