From 8a3b507dea5e4568623abf2d5c925d17da296b5f Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Sat, 29 Aug 2020 23:25:38 +0000 Subject: cosmetic: dissolve error-goto with single source in handover_start() Change-Id: I9c7d10c36f3f868100c1aa2d0433ceed74161175 --- src/osmo-bsc/handover_fsm.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/osmo-bsc/handover_fsm.c b/src/osmo-bsc/handover_fsm.c index 90fa20bb0..bb5dcb14d 100644 --- a/src/osmo-bsc/handover_fsm.c +++ b/src/osmo-bsc/handover_fsm.c @@ -330,8 +330,10 @@ void handover_start(struct handover_out_req *req) ho->target_cell = req->target_nik; if (find_handover_target_cell(&local_target_cell, &remote_target_cell, - conn, search_for, true)) - goto no_handover; + conn, search_for, true)) { + handover_end(conn, HO_RESULT_FAIL_NO_CHANNEL); + return; + } if (local_target_cell) { ho->new_bts = local_target_cell; @@ -346,9 +348,6 @@ void handover_start(struct handover_out_req *req) /* should never reach this, because find_handover_target_cell() would have returned error. */ OSMO_ASSERT(false); - -no_handover: - handover_end(conn, HO_RESULT_FAIL_NO_CHANNEL); } /*! Hand over the specified logical channel to the specified new BTS and possibly change the lchan type. -- cgit v1.2.3