openbsc[master]: Fix BTS features length check

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

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Tue Jun 13 11:56:38 UTC 2017


Patch Set 1: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/2900/1/openbsc/src/libbsc/abis_nm.c
File openbsc/src/libbsc/abis_nm.c:

Line 493: 		if (m_id_len > _NUM_BTS_FEAT/8 + 1)
shouldn't this be

  if (m_id_len > _NUM_BTS_FEAT/8)

? This patch allows m_id_len to be one larger than _NUM_BTS_FEAT/8.

Should the /8 also get a comment? "NUM" sounds like an actual amount; in contrast, division by 8 seems to be some buffer size with each feature taking 8 bytes? Just asking because I'm not familiar...


-- 
To view, visit https://gerrit.osmocom.org/2900
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I06d2498d730624d5da535f6add6fa98d004714ae
Gerrit-PatchSet: 1
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-HasComments: Yes



More information about the gerrit-log mailing list