1
0
mirror of https://git.openwrt.org/feed/packages.git synced 2024-06-13 19:03:52 +02:00
openwrt-packages/utils/bluez/patches/205-refresh_adv_manager_for_non-LE_devices.patch
Daniel Golle 274fc7575e bluez: update to version 5.66
ver 5.66:
Fix issue with A2DP and transport connection collisions.
Fix issue with allowing application specific error codes.
Fix issue with not setting initiator flag correctly.
Fix issue with HoG Report MAP size handling.
Add initial support for Basic Audio Profile.
Add initial support for Volume Control Profile.

ver 5.65:
Fix issue with A2DP cache invalidation handling.
Fix issue with A2DP and not initialized SEP codec.
Fix issue with A2DP and multiple SetConfiguration to same SEP
Fix issue with AVRCP and not properly initialized volume.
Fix issue with SDP records when operating in LE only mode.
Fix issue with HoG and not reading report map of instances.
Fix issue with GATT server crashing while disconnecting.
Fix issue with not removing connected devices.
Fix issue with enabling wake support without RPA Resolution.
Fix issue with pairing failed due to the error of Already Paired.
Add support for CONFIGURATION_DIRECTORY environment variable.
Add support for STATE_DIRECTORY environment variable.
Add support for "Bonded" property with Device API.
Add experimental support for ISO socket.

Package btmon in new package 'bluez-utils-btmon' to prevent adding
glib2 it now requires as a dependency for all of bluez-utils.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2023-01-13 22:04:34 -08:00

48 lines
2.1 KiB
Diff

From 2c3bba7b38be03834162e34069156f1fd49f0528 Mon Sep 17 00:00:00 2001
From: "antoine.belvire@laposte.net" <antoine.belvire@laposte.net>
Date: Tue, 27 Mar 2018 20:30:26 +0200
Subject: adapter: Don't refresh adv_manager for non-LE devices
btd_adv_manager_refresh is called upon MGMT_SETTING_DISCOVERABLE setting change
but as only LE adapters have an adv_manager, this leads to segmentation fault
for non-LE devices:
0 btd_adv_manager_refresh (manager=0x0) at src/advertising.c:1176
1 0x0000556fe45fcb02 in settings_changed (settings=<optimized out>,
adapter=0x556fe53f7c70) at src/adapter.c:543
2 new_settings_callback (index=<optimized out>, length=<optimized out>,
param=<optimized out>, user_data=0x556fe53f7c70) at src/adapter.c:573
3 0x0000556fe462c278 in request_complete (mgmt=mgmt@entry=0x556fe53f20c0,
status=<optimized out>, opcode=opcode@entry=7, index=index@entry=0,
length=length@entry=4, param=0x556fe53eb5f9) at src/shared/mgmt.c:261
4 0x0000556fe462cd9d in can_read_data (io=<optimized out>,
user_data=0x556fe53f20c0) at src/shared/mgmt.c:353
5 0x0000556fe46396e3 in watch_callback (channel=<optimized out>,
cond=<optimized out>, user_data=<optimized out>)
at src/shared/io-glib.c:170
6 0x00007fe351c980e5 in g_main_context_dispatch ()
from /usr/lib64/libglib-2.0.so.0
7 0x00007fe351c984b0 in ?? () from /usr/lib64/libglib-2.0.so.0
8 0x00007fe351c987c2 in g_main_loop_run () from /usr/lib64/libglib-2.0.so.0
9 0x0000556fe45abc75 in main (argc=<optimized out>, argv=<optimized out>)
at src/main.c:770
This commit prevents the call to btd_adv_manager_refresh for non-LE devices.
---
src/adapter.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/src/adapter.c
+++ b/src/adapter.c
@@ -634,7 +634,9 @@ static void settings_changed(struct btd_
*/
if (!adapter->discovery_discoverable)
store_adapter_info(adapter);
- btd_adv_manager_refresh(adapter->adv_manager);
+
+ if (adapter->supported_settings & MGMT_SETTING_LE)
+ btd_adv_manager_refresh(adapter->adv_manager);
}
if (changed_mask & MGMT_SETTING_BONDABLE) {