osmith has abandoned this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33400 )
Change subject: Fix various uninitialized value errors
......................................................................
Abandoned
thanks for the review, needs to be split up in separate patches etc
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33400
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Icaf53fda8752e9d2bd2cfe8c7b89bb31b90f684f
Gerrit-Change-Number: 33400
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: abandon
Attention is currently required from: osmith, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33400 )
Change subject: Fix various uninitialized value errors
......................................................................
Patch Set 1:
(1 comment)
File tests/codec/codec_ecu_fr_test.c:
https://gerrit.osmocom.org/c/libosmocore/+/33400/comment/8f103b21_9ab92a61
PS1, Line 108: test_fr_concealment
Looking at CID#274685 I see Coverity is complaining about `test_fr_concealment_realistic()`, but you're fixing `test_fr_concealment()`?
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33400
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Icaf53fda8752e9d2bd2cfe8c7b89bb31b90f684f
Gerrit-Change-Number: 33400
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 23 Jun 2023 10:33:12 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
fixeria has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33411 )
Change subject: coding: fix a copy-paste bug in gsm0503_tch_afs_decode_dtx()
......................................................................
coding: fix a copy-paste bug in gsm0503_tch_afs_decode_dtx()
According to 3GPP TS 45.003, section 3.9.2, the convolutional coding
is *not* employed in the case of SID_FIRST. This is why we're using
sid_first_dummy[] in this function.
The conv[] array is not initialized in the case of AFS_SID_FIRST and
passing it to tch_amr_reassemble() is highly likely a copy-paste bug.
Pass the sid_first_dummy[] instead.
Change-Id: Ic8bfc34ce9d14821fe4e82932325f0c517d443a1
Fixes: CID#272949 "Uninitialized scalar variable"
---
M src/coding/gsm0503_coding.c
1 file changed, 19 insertions(+), 1 deletion(-)
Approvals:
Jenkins Builder: Verified
osmith: Looks good to me, but someone else must approve
pespin: Looks good to me, approved
diff --git a/src/coding/gsm0503_coding.c b/src/coding/gsm0503_coding.c
index 80286f7..286981e 100644
--- a/src/coding/gsm0503_coding.c
+++ b/src/coding/gsm0503_coding.c
@@ -2262,7 +2262,7 @@
tch_amr_sid_update_append(sid_first_dummy, 0,
(codec_mode_req) ? codec[*ft]
: codec[id > 0 ? id : 0]);
- tch_amr_reassemble(tch_data, conv, 39);
+ tch_amr_reassemble(tch_data, sid_first_dummy, 39);
len = 5;
goto out;
case AFS_SID_UPDATE: /* TODO: parse CMI _and_ CMC/CMR (16 + 16 bit) */
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33411
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ic8bfc34ce9d14821fe4e82932325f0c517d443a1
Gerrit-Change-Number: 33411
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: merged
Attention is currently required from: osmith, pespin.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33400 )
Change subject: Fix various uninitialized value errors
......................................................................
Patch Set 1:
(2 comments)
File src/gsm/gsm23236.c:
https://gerrit.osmocom.org/c/libosmocore/+/33400/comment/1ea8fbac_133e5aa1
PS1, Line 490: struct osmo_nri_range add_range = {};
> I don't really see a problem with not initializing it, unless osmo_nri_parse_range() requires the fi […]
It's not required to be zero-initialized. The point is that `osmo_nri_parse_range()` inits fields `add_range.{first,last}`, but not `add_range.entry`. The later is initialized by `osmo_nri_ranges_add()` below.
https://gerrit.osmocom.org/c/libosmocore/+/33400/comment/51f14b1a_ea5459a3
PS1, Line 496: if (added_range)
> imho this should be moved after the if in line 499.
Ack, this should do the trick.
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33400
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Icaf53fda8752e9d2bd2cfe8c7b89bb31b90f684f
Gerrit-Change-Number: 33400
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 23 Jun 2023 10:27:31 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: comment
Attention is currently required from: osmith.
fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/33400 )
Change subject: Fix various uninitialized value errors
......................................................................
Patch Set 1:
(1 comment)
File src/coding/gsm0503_coding.c:
https://gerrit.osmocom.org/c/libosmocore/+/33400/comment/be5e7ba6_01042dd9
PS1, Line 2197: conv[250] = {};
> I don't think we should be doing zero-init unconditionally here. […]
This is actually a bug, which is fixed here:
https://gerrit.osmocom.org/c/libosmocore/+/33411
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/33400
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Icaf53fda8752e9d2bd2cfe8c7b89bb31b90f684f
Gerrit-Change-Number: 33400
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Comment-Date: Fri, 23 Jun 2023 10:02:32 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: comment