aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2020-08-10 21:12:46 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2020-08-10 21:25:57 +0200
commit9ed0d17d536194483179c97838af9ecbd88131f1 (patch)
tree0e47485f95702b24da4787c21c917281bbfcefe3
parentf5dab9a2c8b521078031613f62bbf150b0bfcc82 (diff)
hodec2: do not keep candidates with zero requirements met
When check_requirements() returns zero, do not keep such an entry in the candidates list at all. This removes logging confusion, where some "candidates" are still listed even though not meeting any handover requirements. Change-Id: I12e48292d5731cb601165c870b9570003bc488ec
-rw-r--r--src/osmo-bsc/handover_decision_2.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/osmo-bsc/handover_decision_2.c b/src/osmo-bsc/handover_decision_2.c
index 26a8840f1..31919576e 100644
--- a/src/osmo-bsc/handover_decision_2.c
+++ b/src/osmo-bsc/handover_decision_2.c
@@ -861,6 +861,10 @@ static void collect_assignment_candidate(struct gsm_lchan *lchan, struct ho_cand
};
debug_candidate(&c, 0, tchf_count, tchh_count);
+
+ if (!c.requirements)
+ return;
+
clist[*candidates] = c;
(*candidates)++;
}
@@ -966,6 +970,9 @@ static void collect_handover_candidate(struct gsm_lchan *lchan, struct neigh_mea
debug_candidate(&c, av_rxlev, tchf_count, tchh_count);
+ if (!c.requirements)
+ return;
+
clist[*candidates] = c;
(*candidates)++;
}