fixeria has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-bts/+/42508?usp=email )

Change subject: scheduler: trx_sched_is_sacch_fn(): fix returning non-bool
......................................................................

scheduler: trx_sched_is_sacch_fn(): fix returning non-bool

The function is declared `bool` but returns `-EINVAL` on an error path.
`-EINVAL` is `-22`, which in C implicitly converts to `bool true`.
Returning `false` makes more sense when we don't know the MF layout.

Change-Id: Ib2394687815aed4990c3880446176e4c97440667
---
M src/common/scheduler_mframe.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, approved
  laforge: Looks good to me, approved




diff --git a/src/common/scheduler_mframe.c b/src/common/scheduler_mframe.c
index 60b6353..647ffc0 100644
--- a/src/common/scheduler_mframe.c
+++ b/src/common/scheduler_mframe.c
@@ -1009,7 +1009,7 @@

        i = find_sched_mframe_idx(ts_pchan(ts), ts->nr);
        if (i < 0)
-               return -EINVAL;
+               return false;
        sched = &trx_sched_multiframes[i];
        frame = &sched->frames[fn % sched->period];
        if (uplink)

--
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/42508?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings?usp=email

Gerrit-MessageType: merged
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: Ib2394687815aed4990c3880446176e4c97440667
Gerrit-Change-Number: 42508
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <[email protected]>
Gerrit-Reviewer: laforge <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>

Reply via email to