diff options
author | Raghavendra Bhat <raghavendra@redhat.com> | 2018-05-21 14:51:44 -0400 |
---|---|---|
committer | Amar Tumballi <amarts@redhat.com> | 2018-05-24 06:13:01 +0000 |
commit | de9b8c06b89b6129154693f048985554ccc5a7e7 (patch) | |
tree | e2242c01dbc8dd93772bc40d39c2f926ad35706b /xlators/storage/posix/src/posix-inode-fd-ops.c | |
parent | ab18f27bff1bbeeaad3cce8177175dbf6f4c7228 (diff) |
storage/posix: use proper FOP for unwinding readdir(p)
As of now, even for readdirp, posix is unwinding with readdir
signature.
Change-Id: I6440c8a253c5d78bbcc97043e4e6e208e3d47cd1
fixes: bz#1581345
Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com>
Diffstat (limited to 'xlators/storage/posix/src/posix-inode-fd-ops.c')
-rw-r--r-- | xlators/storage/posix/src/posix-inode-fd-ops.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/xlators/storage/posix/src/posix-inode-fd-ops.c b/xlators/storage/posix/src/posix-inode-fd-ops.c index 011dc193d90..4a7385cd271 100644 --- a/xlators/storage/posix/src/posix-inode-fd-ops.c +++ b/xlators/storage/posix/src/posix-inode-fd-ops.c @@ -5166,7 +5166,12 @@ posix_do_readdir (call_frame_t *frame, xlator_t *this, posix_readdirp_fill (this, fd, &entries, dict); out: - STACK_UNWIND_STRICT (readdir, frame, op_ret, op_errno, &entries, NULL); + if (whichop == GF_FOP_READDIR) + STACK_UNWIND_STRICT (readdir, frame, op_ret, op_errno, &entries, + NULL); + else + STACK_UNWIND_STRICT (readdirp, frame, op_ret, op_errno, + &entries, NULL); gf_dirent_free (&entries); @@ -5206,8 +5211,8 @@ posix_readdirp (call_frame_t *frame, xlator_t *this, } } - STACK_UNWIND_STRICT (readdir, frame, op_ret, op_errno, &entries, - NULL); + STACK_UNWIND_STRICT (readdirp, frame, op_ret, op_errno, + &entries, NULL); gf_dirent_free (&entries); return 0; |