From 7d6e73d4421265a304fd22964649e555a2db8097 Mon Sep 17 00:00:00 2001 From: Vikas Gorur Date: Tue, 13 Oct 2009 06:42:13 +0000 Subject: posix/client/server: Send postparent in lookup even if lookup fails on the entry itself. Signed-off-by: Anand V. Avati BUG: 137 (Parent directory mtime not reset after a create in self-heal) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=137 --- xlators/protocol/client/src/client-protocol.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'xlators/protocol/client/src') diff --git a/xlators/protocol/client/src/client-protocol.c b/xlators/protocol/client/src/client-protocol.c index a798ea9f773..a7dbfbf5379 100644 --- a/xlators/protocol/client/src/client-protocol.c +++ b/xlators/protocol/client/src/client-protocol.c @@ -4609,10 +4609,11 @@ client_lookup_cbk (call_frame_t *frame, gf_hdr_common_t *hdr, size_t hdrlen, op_ret = ntoh32 (hdr->rsp.op_ret); + gf_stat_to_stat (&rsp->postparent, &postparent); + if (op_ret == 0) { op_ret = -1; gf_stat_to_stat (&rsp->stat, &stbuf); - gf_stat_to_stat (&rsp->postparent, &postparent); ret = inode_ctx_get (inode, frame->this, &oldino); if (oldino != stbuf.st_ino) { @@ -4664,7 +4665,7 @@ client_lookup_cbk (call_frame_t *frame, gf_hdr_common_t *hdr, size_t hdrlen, } gf_errno = ntoh32 (hdr->rsp.op_errno); op_errno = gf_error_to_errno (gf_errno); - + fail: STACK_UNWIND (frame, op_ret, op_errno, inode, &stbuf, xattr, &postparent); -- cgit