All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ 0/2] Memory leaks and memory used after free fixes
@ 2023-09-27  6:24 Andrei Istodorescu
  2023-09-27  6:24 ` [PATCH BlueZ 1/2] bap: Remove memory leaks and buffer usage after free Andrei Istodorescu
  2023-09-27  6:24 ` [PATCH BlueZ 2/2] shared/bap: Set stream lpac to NULL after removing the stream Andrei Istodorescu
  0 siblings, 2 replies; 5+ messages in thread
From: Andrei Istodorescu @ 2023-09-27  6:24 UTC (permalink / raw)
  To: linux-bluetooth
  Cc: claudia.rosu, mihai-octavian.urzica, silviu.barbulescu,
	vlad.pruteanu, iulia.tanasescu, luiz.dentz, Andrei Istodorescu

This patch fixes memory leaks and usage of unallocated memory.

The endpoint is initialized after allocation, so that it will not
contain random pointers.
Rework parse_base and parse_array. Add missing unregister in
bap_exit.
Set the lpac in the stream to NULL as it is freed in another place and
will result in a dangling pointer inside the stream.

Andrei Istodorescu (2):
  bap: Remove memory leaks and buffer usage after free.
  shared/bap: Set stream lpac to NULL after removing the stream.

 profiles/audio/bap.c | 66 ++++++++++++++++++++++++++------------------
 src/shared/bap.c     |  4 ++-
 2 files changed, 42 insertions(+), 28 deletions(-)


base-commit: df658c6c4ab5bd5ec4a8a3f8faa36e0d0a5f906a
--
2.39.2


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-09-27 21:56 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-27  6:24 [PATCH BlueZ 0/2] Memory leaks and memory used after free fixes Andrei Istodorescu
2023-09-27  6:24 ` [PATCH BlueZ 1/2] bap: Remove memory leaks and buffer usage after free Andrei Istodorescu
2023-09-27  8:02   ` Memory leaks and memory used after free fixes bluez.test.bot
2023-09-27 21:55   ` [PATCH BlueZ 1/2] bap: Remove memory leaks and buffer usage after free Luiz Augusto von Dentz
2023-09-27  6:24 ` [PATCH BlueZ 2/2] shared/bap: Set stream lpac to NULL after removing the stream Andrei Istodorescu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.