diff options
author | Atin Mukherjee <amukherj@redhat.com> | 2019-04-16 22:14:47 +0530 |
---|---|---|
committer | Pranith Kumar Karampuri <pkarampu@redhat.com> | 2019-04-17 08:17:29 +0000 |
commit | 785f3276d2e325a991b64aed66a326ea95fffef3 (patch) | |
tree | 0ccd327225b01e4d3eba2d26051dfe6ff7f335df /xlators/features/locks/src/posix.c | |
parent | b922793588ad23a9b12ce65abd29e8f45ac87998 (diff) |
Revert "features/locks: error-out {inode,entry}lk fops with all-zero lk-owner"
This reverts commit 3883887427a7f2dc458a9773e05f7c8ce8e62301 as it has
broken sdfs-sanity.t.
Updates: bz#1624701
Change-Id: Icb2b0d6bfcce4d556f1cd0f11695c03ffc138736
Signed-off-by: Atin Mukherjee <amukherj@redhat.com>
Diffstat (limited to 'xlators/features/locks/src/posix.c')
-rw-r--r-- | xlators/features/locks/src/posix.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/xlators/features/locks/src/posix.c b/xlators/features/locks/src/posix.c index 6a1f429e8eb..3f1c7a733ff 100644 --- a/xlators/features/locks/src/posix.c +++ b/xlators/features/locks/src/posix.c @@ -2297,10 +2297,9 @@ __fd_has_locks(pl_inode_t *pl_inode, fd_t *fd) static posix_lock_t * lock_dup(posix_lock_t *lock) { - int32_t op_errno = 0; return new_posix_lock(&lock->user_flock, lock->client, lock->client_pid, &lock->owner, (fd_t *)lock->fd_num, lock->lk_flags, - lock->blocking, &op_errno); + lock->blocking); } static int @@ -2517,11 +2516,11 @@ pl_lk(call_frame_t *frame, xlator_t *this, fd_t *fd, int32_t cmd, } reqlock = new_posix_lock(flock, frame->root->client, frame->root->pid, - &frame->root->lk_owner, fd, lk_flags, can_block, - &op_errno); + &frame->root->lk_owner, fd, lk_flags, can_block); if (!reqlock) { op_ret = -1; + op_errno = ENOMEM; goto unwind; } |