diff mbox series

[BlueZ,v1] bass: add NULL check to bass_bcast_src_free()

Message ID 20240628073542.20896-1-r.smirnov@omp.ru
State New
Headers show
Series [BlueZ,v1] bass: add NULL check to bass_bcast_src_free() | expand

Commit Message

Roman Smirnov June 28, 2024, 7:35 a.m. UTC
Make bass_bcast_src_free() safe for passing NULL pointers.
---
 src/shared/bass.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

bluez.test.bot@gmail.com June 28, 2024, 9:44 a.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=866446

---Test result---

Test Summary:
CheckPatch                    PASS      0.30 seconds
GitLint                       PASS      0.22 seconds
BuildEll                      PASS      24.28 seconds
BluezMake                     PASS      1675.34 seconds
MakeCheck                     PASS      13.67 seconds
MakeDistcheck                 PASS      183.04 seconds
CheckValgrind                 PASS      257.89 seconds
CheckSmatch                   PASS      360.58 seconds
bluezmakeextell               PASS      123.47 seconds
IncrementalBuild              PASS      1527.30 seconds
ScanBuild                     PASS      1038.10 seconds



---
Regards,
Linux Bluetooth
diff mbox series

Patch

diff --git a/src/shared/bass.c b/src/shared/bass.c
index c30537dee..d82c043ac 100644
--- a/src/shared/bass.c
+++ b/src/shared/bass.c
@@ -1272,6 +1272,9 @@  static void bass_bcast_src_free(void *data)
 {
 	struct bt_bcast_src *bcast_src = data;
 
+	if (!bcast_src)
+		return;
+
 	for (int i = 0; i < bcast_src->num_subgroups; i++)
 		free(bcast_src->subgroup_data[i].meta);