summaryrefslogtreecommitdiffstats
path: root/xlators/features/locks/src
diff options
context:
space:
mode:
authorPranith Kumar K <pranithk@gluster.com>2012-01-06 15:07:48 +0530
committerAnand Avati <avati@redhat.com>2012-06-01 16:45:12 -0700
commitd19e38aa7c043ae101445706b5c75f61f57f51a1 (patch)
tree8a57f96eda274c361ad175ce720ef3cb74365f4c /xlators/features/locks/src
parent7150f4197bd709da0a8887d5ad35e58ee2eeb72e (diff)
features/locks: update user_flock structure before inserting
Change-Id: Idfa00e4f3263d50b327f5a2c6f13ec68ffc8fbee BUG: 805994 Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Reviewed-on: http://review.gluster.com/3048 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
Diffstat (limited to 'xlators/features/locks/src')
-rw-r--r--xlators/features/locks/src/common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/xlators/features/locks/src/common.c b/xlators/features/locks/src/common.c
index af03cdf2a7a..f59d0882c1a 100644
--- a/xlators/features/locks/src/common.c
+++ b/xlators/features/locks/src/common.c
@@ -803,6 +803,7 @@ __insert_and_merge (pl_inode_t *pl_inode, posix_lock_t *lock)
__destroy_lock (lock);
INIT_LIST_HEAD (&sum->list);
+ posix_lock_to_flock (sum, &sum->user_flock);
__insert_and_merge (pl_inode, sum);
return;
@@ -830,6 +831,8 @@ __insert_and_merge (pl_inode_t *pl_inode, posix_lock_t *lock)
continue;
INIT_LIST_HEAD (&v.locks[i]->list);
+ posix_lock_to_flock (v.locks[i],
+ &v.locks[i]->user_flock);
__insert_and_merge (pl_inode,
v.locks[i]);
}