summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
Diffstat (limited to 'xlators')
-rw-r--r--xlators/cluster/unify/src/unify-self-heal.c20
-rw-r--r--xlators/cluster/unify/src/unify.h8
2 files changed, 14 insertions, 14 deletions
diff --git a/xlators/cluster/unify/src/unify-self-heal.c b/xlators/cluster/unify/src/unify-self-heal.c
index 4e788fc7a..7c62495c2 100644
--- a/xlators/cluster/unify/src/unify-self-heal.c
+++ b/xlators/cluster/unify/src/unify-self-heal.c
@@ -539,9 +539,9 @@ unify_sh_checksum_cbk (call_frame_t *frame,
if (op_ret >= 0) {
if (NS(this) == (xlator_t *)cookie) {
memcpy (local->sh_struct->ns_file_checksum,
- file_checksum, ZR_FILENAME_MAX);
+ file_checksum, NAME_MAX);
memcpy (local->sh_struct->ns_dir_checksum,
- dir_checksum, ZR_FILENAME_MAX);
+ dir_checksum, NAME_MAX);
} else {
if (local->entry_count == 0) {
/* Initialize the dir_checksum to be
@@ -552,12 +552,12 @@ unify_sh_checksum_cbk (call_frame_t *frame,
/* Using 'entry_count' as a flag */
local->entry_count = 1;
memcpy (local->sh_struct->dir_checksum,
- dir_checksum, ZR_FILENAME_MAX);
+ dir_checksum, NAME_MAX);
}
/* Reply from the storage nodes */
for (index = 0;
- index < ZR_FILENAME_MAX; index++) {
+ index < NAME_MAX; index++) {
/* Files should be present in
only one node */
local->sh_struct->file_checksum[index] ^= file_checksum[index];
@@ -573,7 +573,7 @@ unify_sh_checksum_cbk (call_frame_t *frame,
UNLOCK (&frame->lock);
if (!callcnt) {
- for (index = 0; index < ZR_FILENAME_MAX ; index++) {
+ for (index = 0; index < NAME_MAX ; index++) {
if (local->sh_struct->file_checksum[index] !=
local->sh_struct->ns_file_checksum[index]) {
local->failed = 1;
@@ -1038,9 +1038,9 @@ unify_bgsh_checksum_cbk (call_frame_t *frame,
if (op_ret >= 0) {
if (NS(this) == (xlator_t *)cookie) {
memcpy (local->sh_struct->ns_file_checksum,
- file_checksum, ZR_FILENAME_MAX);
+ file_checksum, NAME_MAX);
memcpy (local->sh_struct->ns_dir_checksum,
- dir_checksum, ZR_FILENAME_MAX);
+ dir_checksum, NAME_MAX);
} else {
if (local->entry_count == 0) {
/* Initialize the dir_checksum to be
@@ -1051,12 +1051,12 @@ unify_bgsh_checksum_cbk (call_frame_t *frame,
/* Using 'entry_count' as a flag */
local->entry_count = 1;
memcpy (local->sh_struct->dir_checksum,
- dir_checksum, ZR_FILENAME_MAX);
+ dir_checksum, NAME_MAX);
}
/* Reply from the storage nodes */
for (index = 0;
- index < ZR_FILENAME_MAX; index++) {
+ index < NAME_MAX; index++) {
/* Files should be present in only
one node */
local->sh_struct->file_checksum[index] ^= file_checksum[index];
@@ -1072,7 +1072,7 @@ unify_bgsh_checksum_cbk (call_frame_t *frame,
UNLOCK (&frame->lock);
if (!callcnt) {
- for (index = 0; index < ZR_FILENAME_MAX ; index++) {
+ for (index = 0; index < NAME_MAX ; index++) {
if (local->sh_struct->file_checksum[index] !=
local->sh_struct->ns_file_checksum[index]) {
local->failed = 1;
diff --git a/xlators/cluster/unify/src/unify.h b/xlators/cluster/unify/src/unify.h
index 965436db5..9841e5c7a 100644
--- a/xlators/cluster/unify/src/unify.h
+++ b/xlators/cluster/unify/src/unify.h
@@ -73,10 +73,10 @@ struct unify_private {
typedef struct unify_private unify_private_t;
struct unify_self_heal_struct {
- uint8_t dir_checksum[ZR_FILENAME_MAX];
- uint8_t ns_dir_checksum[ZR_FILENAME_MAX];
- uint8_t file_checksum[ZR_FILENAME_MAX];
- uint8_t ns_file_checksum[ZR_FILENAME_MAX];
+ uint8_t dir_checksum[NAME_MAX];
+ uint8_t ns_dir_checksum[NAME_MAX];
+ uint8_t file_checksum[NAME_MAX];
+ uint8_t ns_file_checksum[NAME_MAX];
off_t *offset_list;
int *count_list;
dir_entry_t **entry_list;