Change in osmo-pcu[master]: bts: fix uninitialized memaccess in BTS::send_gsmtap_rach()

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/.

fixeria gerrit-no-reply at lists.osmocom.org
Wed Jan 13 14:16:04 UTC 2021


fixeria has submitted this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/22008 )

Change subject: bts: fix uninitialized memaccess in BTS::send_gsmtap_rach()
......................................................................

bts: fix uninitialized memaccess in BTS::send_gsmtap_rach()

Unfortunately, RACH.ind on the PCU interface contains no Uplink
measurements: neiter RSSI nor C/I.  In order to avoid sending
garbage, let's zero-initialize 'struct pcu_l1_meas'.

Change-Id: I8c3210c428da17d23d798f3ef9df941ded6e162a
Fixes: CID#216512
---
M src/bts.cpp
1 file changed, 1 insertion(+), 1 deletion(-)

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



diff --git a/src/bts.cpp b/src/bts.cpp
index bd0a1d2..87afc9f 100644
--- a/src/bts.cpp
+++ b/src/bts.cpp
@@ -506,7 +506,7 @@
 void BTS::send_gsmtap_rach(enum pcu_gsmtap_category categ, uint8_t channel,
 			   const struct rach_ind_params *rip)
 {
-	struct pcu_l1_meas meas;
+	struct pcu_l1_meas meas = { 0 };
 	uint8_t ra_buf[2];
 
 	/* 3GPP TS 44.004 defines 11 bit RA as follows: xxxx xxxx  .... .yyy

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

Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: I8c3210c428da17d23d798f3ef9df941ded6e162a
Gerrit-Change-Number: 22008
Gerrit-PatchSet: 2
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210113/df5aa8ab/attachment.htm>


More information about the gerrit-log mailing list