summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2014-08-25 10:42:18 +0200
committerantirez <antirez@gmail.com>2014-08-25 10:42:18 +0200
commit119a7000b5b8e75016dbb554e703bae6e52cb56d (patch)
treea7a471c1317e8a468072c66b53bbe99cda7559a6
parent8eeb1802ec42682a614a5ebca318a0ba44ca7c03 (diff)
downloadredis-119a7000b5b8e75016dbb554e703bae6e52cb56d.tar.gz
Use modern typedef form in cluster.h.
-rw-r--r--src/cluster.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/cluster.h b/src/cluster.h
index 96072cd91..16a060ec4 100644
--- a/src/cluster.h
+++ b/src/cluster.h
@@ -62,12 +62,12 @@ typedef struct clusterLink {
#define nodeFailed(n) ((n)->flags & REDIS_NODE_FAIL)
/* This structure represent elements of node->fail_reports. */
-struct clusterNodeFailReport {
+typedef struct clusterNodeFailReport {
struct clusterNode *node; /* Node reporting the failure condition. */
mstime_t time; /* Time of the last report from this node. */
-} typedef clusterNodeFailReport;
+} clusterNodeFailReport;
-struct clusterNode {
+typedef struct clusterNode {
mstime_t ctime; /* Node object creation time. */
char name[REDIS_CLUSTER_NAMELEN]; /* Node name, hex string, sha1-size */
int flags; /* REDIS_NODE_... */
@@ -87,8 +87,7 @@ struct clusterNode {
int port; /* Latest known port of this node */
clusterLink *link; /* TCP/IP link with this node */
list *fail_reports; /* List of nodes signaling this as failing */
-};
-typedef struct clusterNode clusterNode;
+} clusterNode;
typedef struct clusterState {
clusterNode *myself; /* This node */