pespin has submitted this change and it was merged. ( 
https://gerrit.osmocom.org/c/osmo-trx/+/14787 )

Change subject: driveTxPriorityQueue(): check if message header format is 
supported
......................................................................

driveTxPriorityQueue(): check if message header format is supported

Change-Id: I17abf95f5e23236abccc50476cd59931580f5cd3
---
M Transceiver52M/Transceiver.cpp
1 file changed, 12 insertions(+), 0 deletions(-)

Approvals:
  laforge: Looks good to me, but someone else must approve
  pespin: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/Transceiver52M/Transceiver.cpp b/Transceiver52M/Transceiver.cpp
index 368ed3f..a12c5bc 100644
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -943,6 +943,18 @@
   /* Convert TDMA FN to the host endianness */
   fn = osmo_load32be(&chdr->fn);

+  /* Make sure we support the received header format */
+  switch (chdr->version) {
+  case 0:
+  /* Version 1 has the same format */
+  case 1:
+    break;
+
+  default:
+    LOG(ERR) << "Rx TRXD message with unknown header version " << 
chdr->version;
+    return false;
+  }
+
   LOG(DEBUG) << "rcvd. burst at: " << GSM::Time(fn, chdr->tn);

   int RSSI = (int) buffer[5];

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

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-Change-Id: I17abf95f5e23236abccc50476cd59931580f5cd3
Gerrit-Change-Number: 14787
Gerrit-PatchSet: 4
Gerrit-Owner: fixeria <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>
Gerrit-MessageType: merged

Reply via email to