write-behind: preserve error returned as-is

Change-Id: Ib766403774c1323e0bbddafedeaa47e7fa3a59fa
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 987415
Reviewed-on: http://review.gluster.org/5296
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
This commit is contained in:
Amar Tumballi 2013-07-05 23:50:52 +05:30 committed by Anand Avati
parent 7cfef51189
commit 5fbee7cdad

View File

@ -213,11 +213,7 @@ wb_fd_err (fd_t *fd, xlator_t *this, int32_t *op_errno)
int32_t tmp = 0;
if (fd_ctx_get (fd, this, &value) == 0) {
if (value != EBADF) {
fd_ctx_set (fd, this, EBADF);
}
if (op_errno != NULL) {
if (op_errno) {
tmp = value;
*op_errno = tmp;
}