summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2011-09-05 13:02:54 +0200
committerVolker Lendecke <vlendec@samba.org>2011-09-05 14:58:46 +0200
commit76ba67862f9615ca325d4118496837ca27c710e0 (patch)
tree8c19359946d8a3b3207d0fe72d581d8a0fd1488b /source3
parentd7eb4a4c85c8cfbc6335b311e09de8d3c5081b14 (diff)
downloadsamba-76ba67862f9615ca325d4118496837ca27c710e0.tar.gz
samba-76ba67862f9615ca325d4118496837ca27c710e0.tar.bz2
samba-76ba67862f9615ca325d4118496837ca27c710e0.zip
s3: Reformat msg_idmap.c to match Samba coding
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/msg_idmap.c32
1 files changed, 19 insertions, 13 deletions
diff --git a/source3/smbd/msg_idmap.c b/source3/smbd/msg_idmap.c
index 702f545bb1..00b2a8b0ca 100644
--- a/source3/smbd/msg_idmap.c
+++ b/source3/smbd/msg_idmap.c
@@ -27,10 +27,11 @@
#include "messages.h"
#include "lib/id_cache.h"
-static bool uid_in_use(const struct user_struct* user, uid_t uid)
+static bool uid_in_use(const struct user_struct *user, uid_t uid)
{
while (user) {
- if (user->session_info && (user->session_info->unix_token->uid == uid)) {
+ if (user->session_info &&
+ (user->session_info->unix_token->uid == uid)) {
return true;
}
user = user->next;
@@ -38,12 +39,14 @@ static bool uid_in_use(const struct user_struct* user, uid_t uid)
return false;
}
-static bool gid_in_use(const struct user_struct* user, gid_t gid)
+static bool gid_in_use(const struct user_struct *user, gid_t gid)
{
while (user) {
if (user->session_info != NULL) {
int i;
- struct security_unix_token *utok = user->session_info->unix_token;
+ struct security_unix_token *utok;
+
+ utok = user->session_info->unix_token;
if (utok->gid == gid) {
return true;
}
@@ -58,7 +61,8 @@ static bool gid_in_use(const struct user_struct* user, gid_t gid)
return false;
}
-static bool sid_in_use(const struct user_struct* user, const struct dom_sid* psid)
+static bool sid_in_use(const struct user_struct *user,
+ const struct dom_sid *psid)
{
uid_t uid;
gid_t gid;
@@ -70,8 +74,8 @@ static bool sid_in_use(const struct user_struct* user, const struct dom_sid* psi
return false;
}
-static bool id_in_use(const struct user_struct* user,
- const struct id_cache_ref* id)
+static bool id_in_use(const struct user_struct *user,
+ const struct id_cache_ref *id)
{
switch(id->type) {
case UID:
@@ -87,13 +91,15 @@ static bool id_in_use(const struct user_struct* user,
}
static void id_cache_kill(struct messaging_context *msg_ctx,
- void *private_data,
- uint32_t msg_type,
- struct server_id server_id,
- DATA_BLOB* data)
+ void *private_data,
+ uint32_t msg_type,
+ struct server_id server_id,
+ DATA_BLOB* data)
{
- const char *msg = (data && data->data) ? (const char *)data->data : "<NULL>";
- struct user_struct *validated_users = smbd_server_conn->smb1.sessions.validated_users;
+ const char *msg = (data && data->data)
+ ? (const char *)data->data : "<NULL>";
+ struct user_struct *validated_users =
+ smbd_server_conn->smb1.sessions.validated_users;
struct id_cache_ref id;
if (!id_cache_ref_parse(msg, &id)) {