summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'libglusterfs/src/inode.c')
-rw-r--r--libglusterfs/src/inode.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libglusterfs/src/inode.c b/libglusterfs/src/inode.c
index bd0684398..5b70ce5fe 100644
--- a/libglusterfs/src/inode.c
+++ b/libglusterfs/src/inode.c
@@ -276,6 +276,7 @@ __inode_destroy (inode_t *inode)
{
int index = 0;
xlator_t *xl = NULL;
+ xlator_t *old_THIS = NULL;
if (!inode->_ctx)
goto noctx;
@@ -283,8 +284,11 @@ __inode_destroy (inode_t *inode)
for (index = 0; index < inode->table->xl->ctx->xl_count; index++) {
if (inode->_ctx[index].key) {
xl = (xlator_t *)(long)inode->_ctx[index].key;
+ old_THIS = THIS;
+ THIS = xl;
if (xl->cbks->forget)
xl->cbks->forget (xl, inode);
+ THIS = old_THIS;
}
}