diff options
author | Pranith Kumar K <pkarampu@redhat.com> | 2015-07-15 06:16:54 +0530 |
---|---|---|
committer | Xavier Hernandez <xhernandez@datalab.es> | 2015-07-23 06:30:41 -0700 |
commit | 332cb6a6901c68f0c79070d7103cc7a728ea6d26 (patch) | |
tree | b71016a0efd8d775382e8416e738280a1faf5c0f /xlators/cluster/map | |
parent | 94372373ee355e42dfe1660a50315adb4f019d64 (diff) |
cluster/ec: Handle race between unlock-timer, new lock
Problem:
New lock could come at the time timer is on the way to unlock. This was leading
to crash in timer thread because thread executing new lock can free up the
timer_link->fop and then timer thread will try to access structures already
freed.
Fix:
If the timer event is fired, set lock->release to true and wait for unlock to
complete.
Thanks to Xavi and Bhaskar for helping in confirming that this race is the RC.
Thanks to Kritika for pointing out and explaining how Avati's patch can be used
to fix this bug.
Change-Id: I45fa5470bbc1f03b5f3d133e26d1e0ab24303378
BUG: 1243187
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/11670
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Xavier Hernandez <xhernandez@datalab.es>
Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Diffstat (limited to 'xlators/cluster/map')
0 files changed, 0 insertions, 0 deletions