Change in osmo-bts[master]: osmo-bts-trx/trx_if.c: fix: always initialize bi->burst_len for NOPE.ind

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

laforge gerrit-no-reply at lists.osmocom.org
Tue Nov 19 18:27:43 UTC 2019


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bts/+/16102 )

Change subject: osmo-bts-trx/trx_if.c: fix: always initialize bi->burst_len for NOPE.ind
......................................................................

osmo-bts-trx/trx_if.c: fix: always initialize bi->burst_len for NOPE.ind

A NOPE.ind indicates absence of an Uplink burst, thus it does not
carry a burst. Let's init the burst length to avoid uninitialized
memory access in the scheduler code.

Change-Id: I77f686bf7df385215892e71733a28ff0d90d7222
Fixes: CID#205857
---
M src/osmo-bts-trx/trx_if.c
1 file changed, 3 insertions(+), 1 deletion(-)

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



diff --git a/src/osmo-bts-trx/trx_if.c b/src/osmo-bts-trx/trx_if.c
index dbf7805..5854c06 100644
--- a/src/osmo-bts-trx/trx_if.c
+++ b/src/osmo-bts-trx/trx_if.c
@@ -1018,8 +1018,10 @@
 	if (hdr_len < 0)
 		return hdr_len;
 
-	if (bi.flags & TRX_BI_F_NOPE_IND)
+	if (bi.flags & TRX_BI_F_NOPE_IND) {
+		bi.burst_len = 0;
 		goto skip_burst;
+	}
 
 	/* We're done with the header now */
 	buf_len -= hdr_len;

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

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I77f686bf7df385215892e71733a28ff0d90d7222
Gerrit-Change-Number: 16102
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191119/c6776f77/attachment.htm>


More information about the gerrit-log mailing list