From b15c32800dd509bf63d7eab52b620e2ac289e95a Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 17 Dec 2005 16:31:04 +0000 Subject: r12305: Reformatting (This used to be commit f574e980aac5bae5e1e3cc23ec648b69a87eb04a) --- source3/smbd/password.c | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) (limited to 'source3') diff --git a/source3/smbd/password.c b/source3/smbd/password.c index 9ee721089c..e4516be32b 100644 --- a/source3/smbd/password.c +++ b/source3/smbd/password.c @@ -381,9 +381,14 @@ BOOL user_ok(const char *user,int snum, gid_t *groups, size_t n_groups) if (lp_invalid_users(snum)) { str_list_copy(&invalid, lp_invalid_users(snum)); - if (invalid && str_list_substitute(invalid, "%S", lp_servicename(snum))) { - if ( invalid && str_list_sub_basic(invalid, current_user_info.smb_name) ) { - ret = !user_in_list(user, (const char **)invalid, groups, n_groups); + if (invalid && + str_list_substitute(invalid, "%S", lp_servicename(snum))) { + if ( invalid && + str_list_sub_basic(invalid, + current_user_info.smb_name) ) { + ret = !user_in_list(user, + (const char **)invalid, + groups, n_groups); } } } @@ -392,9 +397,13 @@ BOOL user_ok(const char *user,int snum, gid_t *groups, size_t n_groups) if (ret && lp_valid_users(snum)) { str_list_copy(&valid, lp_valid_users(snum)); - if ( valid && str_list_substitute(valid, "%S", lp_servicename(snum)) ) { - if ( valid && str_list_sub_basic(valid, current_user_info.smb_name) ) { - ret = user_in_list(user, (const char **)valid, groups, n_groups); + if ( valid && + str_list_substitute(valid, "%S", lp_servicename(snum)) ) { + if ( valid && + str_list_sub_basic(valid, + current_user_info.smb_name) ) { + ret = user_in_list(user, (const char **)valid, + groups, n_groups); } } } @@ -403,8 +412,11 @@ BOOL user_ok(const char *user,int snum, gid_t *groups, size_t n_groups) if (ret && lp_onlyuser(snum)) { char **user_list = str_list_make (lp_username(snum), NULL); - if (user_list && str_list_substitute(user_list, "%S", lp_servicename(snum))) { - ret = user_in_list(user, (const char **)user_list, groups, n_groups); + if (user_list && + str_list_substitute(user_list, "%S", + lp_servicename(snum))) { + ret = user_in_list(user, (const char **)user_list, + groups, n_groups); } if (user_list) str_list_free (&user_list); } -- cgit