diff options
author | Amar Tumballi <amar@gluster.com> | 2010-09-07 10:13:29 +0000 |
---|---|---|
committer | Vijay Bellur <vijay@dev.gluster.com> | 2010-09-07 09:41:26 -0700 |
commit | 6b4784d5382fb3177e423751eb8d056e8bf384b4 (patch) | |
tree | 56f3c8389f1bc0ed13f1c6c5cb7c9f279542ea65 | |
parent | ed561b78d9837b9f799ebb410bcc26b7e5413f33 (diff) |
fuse resolve to return if resolve not successful
Signed-off-by: Amar Tumballi <amar@gluster.com>
Signed-off-by: Vijay Bellur <vijay@dev.gluster.com>
BUG: 1406 ()
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1406
-rw-r--r-- | xlators/mount/fuse/src/fuse-resolve.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/xlators/mount/fuse/src/fuse-resolve.c b/xlators/mount/fuse/src/fuse-resolve.c index 3bdc0b9293e..dd248f3d9bc 100644 --- a/xlators/mount/fuse/src/fuse-resolve.c +++ b/xlators/mount/fuse/src/fuse-resolve.c @@ -145,6 +145,8 @@ fuse_resolve_newfd_cbk (call_frame_t *frame, void *cookie, xlator_t *this, STACK_DESTROY (frame->root); if (op_ret == -1) { + resolve->op_ret = -1; + resolve->op_errno = op_errno; goto out; } @@ -631,7 +633,7 @@ gf_resolve (fuse_state_t *state) } else { - resolve->op_ret = -1; + resolve->op_ret = 0; resolve->op_errno = EINVAL; gf_resolve_all (state); @@ -646,10 +648,17 @@ gf_resolve_done (fuse_state_t *state) { fuse_resume_fn_t fn = NULL; + if (state->resolve.op_ret || state->resolve2.op_ret) { + send_fuse_err (state->this, state->finh, + state->resolve.op_errno); + free_fuse_state (state); + goto out; + } fn = state->resume_fn; if (fn) fn (state); +out: return 0; } |