Blame SOURCES/0469-storage-posix-Set-ret-value-correctly-before-exiting.patch
|
|
21ab4e |
From 3d70204c4f6d36d3c5429ca162193d452eeb7102 Mon Sep 17 00:00:00 2001
|
|
|
21ab4e |
From: Krutika Dhananjay <kdhananj@redhat.com>
|
|
|
21ab4e |
Date: Wed, 1 Mar 2017 12:48:10 +0530
|
|
|
21ab4e |
Subject: [PATCH 469/473] storage/posix: Set ret value correctly before exiting
|
|
|
21ab4e |
|
|
|
21ab4e |
Backport of: https://review.gluster.org/16792
|
|
|
21ab4e |
|
|
|
21ab4e |
Change-Id: I942d009c4582a5aeb60b06fe7c2ef8589e8e71c3
|
|
|
21ab4e |
BUG: 1415178
|
|
|
21ab4e |
Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
|
|
|
21ab4e |
Reviewed-on: https://code.engineering.redhat.com/gerrit/106797
|
|
|
21ab4e |
Reviewed-by: Raghavendra Gowdappa <rgowdapp@redhat.com>
|
|
|
21ab4e |
---
|
|
|
21ab4e |
xlators/storage/posix/src/posix-handle.c | 4 +++-
|
|
|
21ab4e |
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
21ab4e |
|
|
|
21ab4e |
diff --git a/xlators/storage/posix/src/posix-handle.c b/xlators/storage/posix/src/posix-handle.c
|
|
|
21ab4e |
index ef56d10..3c8e241 100644
|
|
|
21ab4e |
--- a/xlators/storage/posix/src/posix-handle.c
|
|
|
21ab4e |
+++ b/xlators/storage/posix/src/posix-handle.c
|
|
|
21ab4e |
@@ -978,8 +978,10 @@ posix_create_link_if_gfid_exists (xlator_t *this, uuid_t gfid, char *real_path,
|
|
|
21ab4e |
if (ret)
|
|
|
21ab4e |
goto unlock;
|
|
|
21ab4e |
|
|
|
21ab4e |
- if (ctx->unlink_flag != GF_UNLINK_TRUE)
|
|
|
21ab4e |
+ if (ctx->unlink_flag != GF_UNLINK_TRUE) {
|
|
|
21ab4e |
+ ret = -1;
|
|
|
21ab4e |
goto unlock;
|
|
|
21ab4e |
+ }
|
|
|
21ab4e |
|
|
|
21ab4e |
POSIX_GET_FILE_UNLINK_PATH (priv->base_path, gfid,
|
|
|
21ab4e |
unlink_path);
|
|
|
21ab4e |
--
|
|
|
21ab4e |
1.8.3.1
|
|
|
21ab4e |
|