Attention is currently required from: neels, pespin.
laforge has posted comments on this change. (
https://gerrit.osmocom.org/c/osmo-hnbgw/+/33158 )
Change subject: coverity: fix type of local var
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
File src/osmo-hnbgw/context_map.c:
https://gerrit.osmocom.org/c/osmo-hnbgw/+/33158/comment/07386f4c_36dee117
PS1, Line 99: if (new_scu_conn_id < 0) {
yes, and 64bit arch still have 32 bit int afair, so it
will fail in most architectures :)
At second review, I don't really understand
your concern, pespin. osmo_sccp_instance_next_conn_id does return an int. So the local
variable should be an int, like this patch does. The function either returns a positive
integer 0x00000000 .. 0x00fffffe or it returns a negative value on error. The fact that
the SCCP references are 24bit values means we never get anywhere near the 32bit MSB
indicating negative values.
So to summarize: I think this patch is correct as-is.
--
To view, visit
https://gerrit.osmocom.org/c/osmo-hnbgw/+/33158
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I2623c06c23691acb75f6ee6ff3a42ac7d10a4b1f
Gerrit-Change-Number: 33158
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Sat, 03 Jun 2023 12:43:29 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment