summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libglusterfs/src/fd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libglusterfs/src/fd.c b/libglusterfs/src/fd.c
index 08e55b724..a4d3b08de 100644
--- a/libglusterfs/src/fd.c
+++ b/libglusterfs/src/fd.c
@@ -811,7 +811,6 @@ __fd_ctx_set (fd_t *fd, xlator_t *xlator, uint64_t value)
new_xl_count = fd->xl_count + xlator->graph->xl_count;
- begin = fd->_ctx;
tmp = GF_REALLOC (fd->_ctx,
(sizeof (struct _fd_ctx)
* new_xl_count));
@@ -826,6 +825,7 @@ __fd_ctx_set (fd_t *fd, xlator_t *xlator, uint64_t value)
fd->_ctx = tmp;
+ begin = fd->_ctx;
begin += (fd->xl_count * sizeof (struct _fd_ctx));
diff = (new_xl_count - fd->xl_count )