Description of problem: See the following code: max_ret = 0; for (i = 0; i < finfo->stripe_count; i++) { memset(buf[i], 0, 4096); <---- here ret = read(finfo->fd[i], buf[i], 4096); if (ret > max_ret) max_ret = ret; } for (i = 0; i < max_ret; i++) for (j = 0; j < finfo->stripe_count; j++) newbuf[i] |= buf[j][i]; write(target, newbuf, max_ret); There is no need to memset the whole 4K, we are reading from the file, writing as much as needed to it. You should memset (4096 - ret) after reading.
Not planning to work any more on the component: https://lists.gluster.org/pipermail/gluster-users/2018-July/034400.html