[sheepdog] [PATCH 2/5] remove spaces where they are prohibited

MORITA Kazutaka morita.kazutaka at gmail.com
Fri Feb 22 01:38:39 CET 2013


From: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>

Signed-off-by: MORITA Kazutaka <morita.kazutaka at lab.ntt.co.jp>
---
 include/list.h           |    4 ++--
 lib/sha1.c               |    4 ++--
 sheep/cluster/corosync.c |    4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/include/list.h b/include/list.h
index 679c0d9..723e1bd 100644
--- a/include/list.h
+++ b/include/list.h
@@ -6,8 +6,8 @@
 #include <stddef.h>
 
 #define container_of(ptr, type, member) ({			\
-	const typeof( ((type *)0)->member ) *__mptr = (ptr);	\
-	(type *)( (char *)__mptr - offsetof(type, member) ); })
+	const typeof(((type *)0)->member) *__mptr = (ptr);	\
+	(type *)((char *)__mptr - offsetof(type, member)); })
 
 struct list_head {
 	struct list_head *next, *prev;
diff --git a/lib/sha1.c b/lib/sha1.c
index 3890ae0..ac8a73a 100644
--- a/lib/sha1.c
+++ b/lib/sha1.c
@@ -61,7 +61,7 @@ static void sha1_transform(uint32_t *state, const uint8_t *in)
 
 	/* convert/copy data to workspace */
 	for (a = 0; a < sizeof(block32)/sizeof(uint32_t); a++)
-	  block32[a] = ntohl (((const uint32_t *)in)[a]);
+	  block32[a] = ntohl(((const uint32_t *)in)[a]);
 
 	/* Copy context->state[] to working vars */
 	a = state[0];
@@ -191,7 +191,7 @@ void sha1_final(void *ctx, uint8_t *out)
 		out[j+3] = t2 & 0xff; t2 >>= 8;
 		out[j+2] = t2 & 0xff; t2 >>= 8;
 		out[j+1] = t2 & 0xff; t2 >>= 8;
-		out[j  ] = t2 & 0xff;
+		out[j] = t2 & 0xff;
 	}
 
 	/* Wipe context */
diff --git a/sheep/cluster/corosync.c b/sheep/cluster/corosync.c
index 176ac83..e732e99 100644
--- a/sheep/cluster/corosync.c
+++ b/sheep/cluster/corosync.c
@@ -81,8 +81,8 @@ struct corosync_event {
 
 struct corosync_message {
 	struct cpg_node sender;
-	enum corosync_message_type type : 4;
-	enum cluster_join_result result : 4;
+	enum corosync_message_type type:4;
+	enum cluster_join_result result:4;
 	uint32_t msg_len;
 	uint32_t nr_nodes;
 	struct cpg_node nodes[SD_MAX_NODES];
-- 
1.7.9.5




More information about the sheepdog mailing list