diff mbox series

[BlueZ,1/4] shared/bap: Fix uninitialized field at BASE generation

Message ID 20240510142754.3901-2-iulia.tanasescu@nxp.com
State New
Headers show
Series test-bap: Add Broadcast Source SCC tests | expand

Commit Message

Iulia Tanasescu May 10, 2024, 2:27 p.m. UTC
Currently in bt_bap_stream_get_base, the pres_delay inside the base
variable is left uninitialized and it is later accessed in
set_base_subgroup, to be compared to each stream presentation delay.

This commit adds a fix by initializing the pres_delay field to the
current stream presentation delay, before later updating it based on
comparison.
---
 src/shared/bap.c | 1 +
 1 file changed, 1 insertion(+)

Comments

bluez.test.bot@gmail.com May 10, 2024, 5:25 p.m. UTC | #1
This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=852321

---Test result---

Test Summary:
CheckPatch                    PASS      2.14 seconds
GitLint                       PASS      1.14 seconds
BuildEll                      PASS      24.47 seconds
BluezMake                     PASS      1734.52 seconds
MakeCheck                     PASS      13.09 seconds
MakeDistcheck                 PASS      180.83 seconds
CheckValgrind                 PASS      254.71 seconds
CheckSmatch                   WARNING   354.07 seconds
bluezmakeextell               PASS      119.42 seconds
IncrementalBuild              PASS      6418.85 seconds
ScanBuild                     PASS      1009.54 seconds

Details
##############################
Test: CheckSmatch - WARNING
Desc: Run smatch tool with source
Output:
src/shared/bap.c:282:25: warning: array of flexible structuressrc/shared/bap.c: note: in included file:./src/shared/ascs.h:88:25: warning: array of flexible structuressrc/shared/bap.c:282:25: warning: array of flexible structuressrc/shared/bap.c: note: in included file:./src/shared/ascs.h:88:25: warning: array of flexible structuressrc/shared/bap.c:282:25: warning: array of flexible structuressrc/shared/bap.c: note: in included file:./src/shared/ascs.h:88:25: warning: array of flexible structures


---
Regards,
Linux Bluetooth
diff mbox series

Patch

diff --git a/src/shared/bap.c b/src/shared/bap.c
index 818326f45..1316d7c73 100644
--- a/src/shared/bap.c
+++ b/src/shared/bap.c
@@ -6321,6 +6321,7 @@  struct iovec *bt_bap_stream_get_base(struct bt_bap_stream *stream)
 	base.subgroups = queue_new();
 	base.next_bis_index = 1;
 	base.big_id = stream->qos.bcast.big;
+	base.pres_delay = stream->qos.bcast.delay;
 
 	/* If the BIG ID was explicitly set, create a BASE with information
 	 * from all streams belonging to this BIG. Otherwise, create a BASE