From: wang di Date: Tue, 11 Aug 2015 11:19:43 +0000 (-0700) Subject: LU-6977 lod: do_index_try should be called first X-Git-Tag: 2.7.59~43 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=35308b05d9a44b0f25534a7a9caf41c01af45ac2 LU-6977 lod: do_index_try should be called first In lod_striped_it_next do_index_try should be called first to initialize do_index_ops, then checking do_index_ops. Signed-off-by: wang di Change-Id: I477fb3c9ccd65c4e7721d78a3746f64acf8733ce Reviewed-on: http://review.whamcloud.com/15972 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Alex Zhuravlev Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- diff --git a/lustre/lod/lod_object.c b/lustre/lod/lod_object.c index 255b8c8..ff13bda 100644 --- a/lustre/lod/lod_object.c +++ b/lustre/lod/lod_object.c @@ -571,12 +571,12 @@ again: next = lo->ldo_stripe[it->lit_stripe_index]; LASSERT(next != NULL); - LASSERT(next->do_index_ops != NULL); - rc = next->do_ops->do_index_try(env, next, &dt_directory_features); if (rc != 0) RETURN(rc); + LASSERT(next->do_index_ops != NULL); + it_next = next->do_index_ops->dio_it.init(env, next, it->lit_attr); if (!IS_ERR(it_next)) { it->lit_it = it_next;