summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2001-08-13 02:33:24 +0000
committerTim Potter <tpot@samba.org>2001-08-13 02:33:24 +0000
commit6b60c28acca29f3803b9065f4969933188c45153 (patch)
tree1d5822c495b63c314edb2ab1d411a7de9e6ccfb1 /source3/nsswitch
parent4da562d4dc6d197c3a7495672638e0f14838d38c (diff)
downloadsamba-6b60c28acca29f3803b9065f4969933188c45153.tar.gz
samba-6b60c28acca29f3803b9065f4969933188c45153.tar.bz2
samba-6b60c28acca29f3803b9065f4969933188c45153.zip
Fixed up 'orrible formatting.
(This used to be commit 73addddb2e038946e38a6a15f46f61148a49ac08)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/wb_client.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/source3/nsswitch/wb_client.c b/source3/nsswitch/wb_client.c
index f5585557fb..104e91c4d4 100644
--- a/source3/nsswitch/wb_client.c
+++ b/source3/nsswitch/wb_client.c
@@ -52,7 +52,8 @@ static void parse_domain_user(char *domuser, fstring domain, fstring user)
/* Call winbindd to convert a name to a sid */
-BOOL winbind_lookup_name(const char *name, DOM_SID *sid, enum SID_NAME_USE *name_type)
+BOOL winbind_lookup_name(const char *name, DOM_SID *sid,
+ enum SID_NAME_USE *name_type)
{
struct winbindd_request request;
struct winbindd_response response;
@@ -79,7 +80,8 @@ BOOL winbind_lookup_name(const char *name, DOM_SID *sid, enum SID_NAME_USE *name
/* Call winbindd to convert sid to name */
-BOOL winbind_lookup_sid(DOM_SID *sid, fstring dom_name, fstring name, enum SID_NAME_USE *name_type)
+BOOL winbind_lookup_sid(DOM_SID *sid, fstring dom_name, fstring name,
+ enum SID_NAME_USE *name_type)
{
struct winbindd_request request;
struct winbindd_response response;
@@ -103,7 +105,9 @@ BOOL winbind_lookup_sid(DOM_SID *sid, fstring dom_name, fstring name, enum SID_N
if (result == NSS_STATUS_SUCCESS) {
parse_domain_user(response.data.name.name, dom_name, name);
*name_type = (enum SID_NAME_USE)response.data.name.type;
- DEBUG(10,("winbind_lookup_sid: SUCCESS: SID %s -> %s %s\n", sid_str, dom_name, name ));
+
+ DEBUG(10, ("winbind_lookup_sid: SUCCESS: SID %s -> %s %s\n",
+ sid_str, dom_name, name));
}
return (result == NSS_STATUS_SUCCESS);
@@ -380,9 +384,7 @@ int winbind_getgroups(char *user, int size, gid_t *list)
return result;
}
-/**********************************************************************************
- Utility function. Convert a uid_t to a name if possible.
-**********************************************************************************/
+/* Utility function. Convert a uid_t to a name if possible. */
BOOL winbind_uidtoname(fstring name, uid_t uid)
{
@@ -399,13 +401,13 @@ BOOL winbind_uidtoname(fstring name, uid_t uid)
if (name_type != SID_NAME_USER)
return False;
- slprintf(name, sizeof(fstring)-1, "%s%s%s", dom_name, lp_winbind_separator(), user_name );
+ slprintf(name, sizeof(fstring)-1, "%s%s%s", dom_name,
+ lp_winbind_separator(), user_name);
+
return True;
}
-/**********************************************************************************
- Utility function. Convert a gid_t to a name if possible.
-**********************************************************************************/
+/* Utility function. Convert a gid_t to a name if possible. */
BOOL winbind_gidtoname(fstring name, gid_t gid)
{
@@ -422,13 +424,13 @@ BOOL winbind_gidtoname(fstring name, gid_t gid)
if (name_type != SID_NAME_USER)
return False;
- slprintf(name, sizeof(fstring)-1, "%s%s%s", dom_name, lp_winbind_separator(), group_name );
+ slprintf(name, sizeof(fstring)-1, "%s%s%s", dom_name,
+ lp_winbind_separator(), group_name);
+
return True;
}
-/**********************************************************************************
- Utility function. Convert a name to a uid_t if possible.
-**********************************************************************************/
+/* Utility function. Convert a name to a uid_t if possible. */
BOOL winbind_nametouid(uid_t *puid, char *name)
{
@@ -436,8 +438,8 @@ BOOL winbind_nametouid(uid_t *puid, char *name)
enum SID_NAME_USE name_type;
if (!winbind_lookup_name(name, &sid, &name_type)) {
- return False;
- }
+ return False;
+ }
if (name_type != SID_NAME_USER)
return False;
@@ -445,9 +447,7 @@ BOOL winbind_nametouid(uid_t *puid, char *name)
return winbind_sid_to_uid(puid, &sid);
}
-/**********************************************************************************
- Utility function. Convert a name to a gid_t if possible.
-**********************************************************************************/
+/* Utility function. Convert a name to a gid_t if possible. */
BOOL winbind_nametogid(gid_t *pgid, char *gname)
{
@@ -455,8 +455,8 @@ BOOL winbind_nametogid(gid_t *pgid, char *gname)
enum SID_NAME_USE name_type;
if (!winbind_lookup_name(gname, &g_sid, &name_type)) {
- return False;
- }
+ return False;
+ }
if (name_type != SID_NAME_DOM_GRP)
return False;