Blame SOURCES/0046-storage-posix-Handle-MAKE_INODE_HANDLE-failures.patch
|
|
cb8e9e |
From 07e29eabdf3fc3cede375a2ac63635dc5dbc385a Mon Sep 17 00:00:00 2001
|
|
|
cb8e9e |
From: Pranith Kumar K <pkarampu@redhat.com>
|
|
|
cb8e9e |
Date: Mon, 1 Jun 2015 13:34:33 +0530
|
|
|
cb8e9e |
Subject: [PATCH 46/57] storage/posix: Handle MAKE_INODE_HANDLE failures
|
|
|
cb8e9e |
|
|
|
cb8e9e |
Backport of http://review.gluster.com/11028
|
|
|
cb8e9e |
|
|
|
cb8e9e |
Change-Id: Ia176ccd4cac82c66ba50e3896fbe72c2da860c20
|
|
|
cb8e9e |
BUG: 1228496
|
|
|
cb8e9e |
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
|
|
|
cb8e9e |
Reviewed-on: https://code.engineering.redhat.com/gerrit/50506
|
|
|
cb8e9e |
---
|
|
|
cb8e9e |
xlators/storage/posix/src/posix.c | 8 +++++++-
|
|
|
cb8e9e |
1 files changed, 7 insertions(+), 1 deletions(-)
|
|
|
cb8e9e |
|
|
|
cb8e9e |
diff --git a/xlators/storage/posix/src/posix.c b/xlators/storage/posix/src/posix.c
|
|
|
cb8e9e |
index 71b83c2..2a1df28 100644
|
|
|
cb8e9e |
--- a/xlators/storage/posix/src/posix.c
|
|
|
cb8e9e |
+++ b/xlators/storage/posix/src/posix.c
|
|
|
cb8e9e |
@@ -4921,8 +4921,14 @@ do_xattrop (call_frame_t *frame, xlator_t *this, loc_t *loc, fd_t *fd,
|
|
|
cb8e9e |
_fd = pfd->fd;
|
|
|
cb8e9e |
}
|
|
|
cb8e9e |
|
|
|
cb8e9e |
- if (loc && !gf_uuid_is_null (loc->gfid))
|
|
|
cb8e9e |
+ if (loc && !gf_uuid_is_null (loc->gfid)) {
|
|
|
cb8e9e |
MAKE_INODE_HANDLE (real_path, this, loc, NULL);
|
|
|
cb8e9e |
+ if (!real_path) {
|
|
|
cb8e9e |
+ op_ret = -1;
|
|
|
cb8e9e |
+ op_errno = ESTALE;
|
|
|
cb8e9e |
+ goto out;
|
|
|
cb8e9e |
+ }
|
|
|
cb8e9e |
+ }
|
|
|
cb8e9e |
|
|
|
cb8e9e |
if (real_path) {
|
|
|
cb8e9e |
inode = loc->inode;
|
|
|
cb8e9e |
--
|
|
|
cb8e9e |
1.7.1
|
|
|
cb8e9e |
|