Change in osmo-bts[master]: sysinfo: fix less-than-zero comparison of an unsigned value

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
Tue Jan 5 12:17:45 UTC 2021


fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/21942 )


Change subject: sysinfo: fix less-than-zero comparison of an unsigned value
......................................................................

sysinfo: fix less-than-zero comparison of an unsigned value

size_t is an unsigned type, while get_si4_ro_offset() returns int.

Change-Id: I3b216b70fbcc653ced734835ccb2c7f1932d9f0a
Fixes: CID#215888
---
M src/common/sysinfo.c
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/42/21942/1

diff --git a/src/common/sysinfo.c b/src/common/sysinfo.c
index 9eea539..d1f6f36 100644
--- a/src/common/sysinfo.c
+++ b/src/common/sysinfo.c
@@ -240,8 +240,8 @@
 void regenerate_si4_restoctets(struct gsm_bts *bts)
 {
 	uint8_t *si4_buf = GSM_BTS_SI(bts, SYSINFO_TYPE_4);
-	size_t si4_size;
 	struct osmo_gsm48_si_ro_info si4ro_tmp;
+	int si4_size;
 
 	/* If BSC has never set SI4, there's nothing to patch */
 	if (!GSM_BTS_HAS_SI(bts, SYSINFO_TYPE_4))

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

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I3b216b70fbcc653ced734835ccb2c7f1932d9f0a
Gerrit-Change-Number: 21942
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210105/7c0a01f6/attachment.htm>


More information about the gerrit-log mailing list