[Sheepdog] [PATCH 3/6] correct the plural of 'one sheep' to be 'two sheep' everywhere
Chris Webb
chris at arachsys.com
Fri Nov 4 18:08:33 CET 2011
Signed-off-by: Chris Webb <chris at arachsys.com>
---
sheep/cluster/corosync.c | 22 +++++++++++-----------
sheep/sheep_priv.h | 2 +-
sheep/store.c | 4 ++--
3 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/sheep/cluster/corosync.c b/sheep/cluster/corosync.c
index 8206084..9ac408e 100644
--- a/sheep/cluster/corosync.c
+++ b/sheep/cluster/corosync.c
@@ -508,23 +508,23 @@ static void cdrv_cpg_confchg(cpg_handle_t handle,
{
struct corosync_event *cevent;
int i;
- struct cpg_node joined_sheeps[SD_MAX_NODES];
- struct cpg_node left_sheeps[SD_MAX_NODES];
+ struct cpg_node joined_sheep[SD_MAX_NODES];
+ struct cpg_node left_sheep[SD_MAX_NODES];
/* convert cpg_address to cpg_node */
for (i = 0; i < left_list_entries; i++) {
- left_sheeps[i].nodeid = left_list[i].nodeid;
- left_sheeps[i].pid = left_list[i].pid;
+ left_sheep[i].nodeid = left_list[i].nodeid;
+ left_sheep[i].pid = left_list[i].pid;
}
for (i = 0; i < joined_list_entries; i++) {
- joined_sheeps[i].nodeid = joined_list[i].nodeid;
- joined_sheeps[i].pid = joined_list[i].pid;
+ joined_sheep[i].nodeid = joined_list[i].nodeid;
+ joined_sheep[i].pid = joined_list[i].pid;
}
/* dispatch leave_handler */
for (i = 0; i < left_list_entries; i++) {
cevent = find_block_event(COROSYNC_EVENT_TYPE_JOIN,
- left_sheeps + i);
+ left_sheep + i);
if (cevent) {
/* the node left before joining */
list_del(&cevent->list);
@@ -534,7 +534,7 @@ static void cdrv_cpg_confchg(cpg_handle_t handle,
}
cevent = find_block_event(COROSYNC_EVENT_TYPE_NOTIFY,
- left_sheeps + i);
+ left_sheep + i);
if (cevent) {
/* the node left before sending UNBLOCK */
list_del(&cevent->list);
@@ -547,7 +547,7 @@ static void cdrv_cpg_confchg(cpg_handle_t handle,
panic("failed to allocate memory\n");
cevent->type = COROSYNC_EVENT_TYPE_LEAVE;
- cevent->sender = left_sheeps[i];
+ cevent->sender = left_sheep[i];
list_add_tail(&cevent->list, &corosync_event_list);
}
@@ -559,10 +559,10 @@ static void cdrv_cpg_confchg(cpg_handle_t handle,
panic("failed to allocate memory\n");
cevent->type = COROSYNC_EVENT_TYPE_JOIN;
- cevent->sender = joined_sheeps[i];
+ cevent->sender = joined_sheep[i];
cevent->blocked = 1; /* FIXME: add explanation */
if (member_list_entries == joined_list_entries - left_list_entries &&
- cpg_node_equal(&joined_sheeps[0], &this_node))
+ cpg_node_equal(&joined_sheep[0], &this_node))
cevent->first_node = 1;
list_add_tail(&cevent->list, &corosync_event_list);
diff --git a/sheep/sheep_priv.h b/sheep/sheep_priv.h
index 8a945ea..89a4af5 100644
--- a/sheep/sheep_priv.h
+++ b/sheep/sheep_priv.h
@@ -33,7 +33,7 @@
#define SD_STATUS_JOIN_FAILED 0x00000010
#define SD_STATUS_HALT 0x00000020
-#define SD_RES_NETWORK_ERROR 0x81 /* Network error between sheeps */
+#define SD_RES_NETWORK_ERROR 0x81 /* Network error between sheep */
enum cpg_event_type {
CPG_EVENT_JOIN,
diff --git a/sheep/store.c b/sheep/store.c
index e2e24ec..c25949c 100644
--- a/sheep/store.c
+++ b/sheep/store.c
@@ -232,7 +232,7 @@ out:
return ret;
}
-static int read_from_other_sheeps(struct request *req, uint32_t epoch,
+static int read_from_other_sheep(struct request *req, uint32_t epoch,
uint64_t oid, char *buf, int copies)
{
int ret;
@@ -625,7 +625,7 @@ static int store_queue_request_local(struct request *req, uint32_t epoch)
ret = SD_RES_NO_MEM;
goto out;
}
- ret = read_from_other_sheeps(req, hdr->epoch, hdr->cow_oid, buf,
+ ret = read_from_other_sheep(req, hdr->epoch, hdr->cow_oid, buf,
hdr->copies);
if (ret) {
eprintf("failed to read old object\n");
--
1.7.5.4
More information about the sheepdog
mailing list