Skip to content

Commit

Permalink
Objecter: remove redundant result-check of _calc_target in _map_session.
Browse files Browse the repository at this point in the history
Result-code check is currently redundant since _calc_target never returns a negative value.
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>

(cherry picked from commit 5a6117e)
  • Loading branch information
xiexingguo authored and smithfarm committed Dec 7, 2015
1 parent 43dede3 commit af2ced5
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/osdc/Objecter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2664,10 +2664,7 @@ int Objecter::_calc_target(op_target_t *t, epoch_t *last_force_resend, bool any
int Objecter::_map_session(op_target_t *target, OSDSession **s,
RWLock::Context& lc)
{
int r = _calc_target(target);
if (r < 0) {
return r;
}
_calc_target(target);
return _get_session(target->osd, s, lc);
}

Expand Down

0 comments on commit af2ced5

Please sign in to comment.