From c5d285b173f253be19458a6ba4470671978ab698 Mon Sep 17 00:00:00 2001 From: Sunny Kumar Date: Wed, 24 Oct 2018 15:23:34 +0530 Subject: posix : fix coverity issues in posix-inode-fd-ops.c This patch fixes CID: 1356526 and 1382369 : Argument cannot be negative Change-Id: I1aab5be2d217479db9f67a26b62854a0b38c1747 updates: bz#789278 Signed-off-by: Sunny Kumar --- xlators/storage/posix/src/posix-inode-fd-ops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xlators/storage/posix/src/posix-inode-fd-ops.c b/xlators/storage/posix/src/posix-inode-fd-ops.c index ce73737d3ae..735c5731d55 100644 --- a/xlators/storage/posix/src/posix-inode-fd-ops.c +++ b/xlators/storage/posix/src/posix-inode-fd-ops.c @@ -1029,7 +1029,7 @@ posix_zerofill(call_frame_t *frame, xlator_t *this, fd_t *fd, off_t offset, }; struct posix_private *priv = NULL; int op_ret = -1; - int op_errno = -EINVAL; + int op_errno = EINVAL; dict_t *rsp_xdata = NULL; VALIDATE_OR_GOTO(frame, out); @@ -1065,7 +1065,7 @@ posix_ipc(call_frame_t *frame, xlator_t *this, int32_t op, dict_t *xdata) */ gf_msg(this->name, GF_LOG_ERROR, 0, P_MSG_IPC_NOT_HANDLE, "GF_LOG_IPC(%d) not handled", op); - STACK_UNWIND_STRICT(ipc, frame, -1, -EOPNOTSUPP, NULL); + STACK_UNWIND_STRICT(ipc, frame, -1, EOPNOTSUPP, NULL); return 0; } -- cgit