summaryrefslogtreecommitdiffstats
path: root/xlators/features/quota/src
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/features/quota/src')
-rw-r--r--xlators/features/quota/src/quota.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/xlators/features/quota/src/quota.c b/xlators/features/quota/src/quota.c
index c014c99cbd2..34dac481a64 100644
--- a/xlators/features/quota/src/quota.c
+++ b/xlators/features/quota/src/quota.c
@@ -560,15 +560,14 @@ quota_handle_validate_error(call_frame_t *frame, int32_t op_ret,
if (local == NULL)
goto out;
- LOCK(&local->lock);
- {
- if (op_ret < 0) {
+ if (op_ret < 0) {
+ LOCK(&local->lock);
+ {
local->op_ret = op_ret;
local->op_errno = op_errno;
}
+ UNLOCK(&local->lock);
}
- UNLOCK(&local->lock);
-
/* we abort checking limits on this path to root */
quota_link_count_decrement(frame);
out: