diff options
-rw-r--r-- | meta/recipes-connectivity/bluez5/bluez5.inc | 1 | ||||
-rw-r--r-- | meta/recipes-connectivity/bluez5/bluez5/toolsbtmgmt-fix-index-option-for-non-interactive-mode.patch | 29 |
2 files changed, 30 insertions, 0 deletions
diff --git a/meta/recipes-connectivity/bluez5/bluez5.inc b/meta/recipes-connectivity/bluez5/bluez5.inc index 731bfa0e40..53d8644159 100644 --- a/meta/recipes-connectivity/bluez5/bluez5.inc +++ b/meta/recipes-connectivity/bluez5/bluez5.inc | |||
@@ -57,6 +57,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/bluetooth/bluez-${PV}.tar.xz \ | |||
57 | file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ | 57 | file://0001-tests-add-a-target-for-building-tests-without-runnin.patch \ |
58 | file://0001-test-gatt-Fix-hung-issue.patch \ | 58 | file://0001-test-gatt-Fix-hung-issue.patch \ |
59 | file://0001-adapter-Fix-up-address-type-when-loading-keys.patch \ | 59 | file://0001-adapter-Fix-up-address-type-when-loading-keys.patch \ |
60 | file://toolsbtmgmt-fix-index-option-for-non-interactive-mode.patch \ | ||
60 | " | 61 | " |
61 | S = "${WORKDIR}/bluez-${PV}" | 62 | S = "${WORKDIR}/bluez-${PV}" |
62 | 63 | ||
diff --git a/meta/recipes-connectivity/bluez5/bluez5/toolsbtmgmt-fix-index-option-for-non-interactive-mode.patch b/meta/recipes-connectivity/bluez5/bluez5/toolsbtmgmt-fix-index-option-for-non-interactive-mode.patch new file mode 100644 index 0000000000..f4e14be146 --- /dev/null +++ b/meta/recipes-connectivity/bluez5/bluez5/toolsbtmgmt-fix-index-option-for-non-interactive-mode.patch | |||
@@ -0,0 +1,29 @@ | |||
1 | From f00d5546c9e989dd68ce0de0190cd0e043b0f1f5 Mon Sep 17 00:00:00 2001 | ||
2 | From: Arjan Opmeer <arjan.opmeer@gmail.com> | ||
3 | Date: Tue, 9 Jul 2024 13:55:41 +0200 | ||
4 | Subject: [PATCH] tools/btmgmt: Fix --index option for non-interactive mode | ||
5 | |||
6 | In non-interactive mode the --index option does not work because the | ||
7 | call to mgmt_set_index() is made after bt_shell_attach(). | ||
8 | |||
9 | Fixes: https://github.com/bluez/bluez/issues/893 | ||
10 | |||
11 | Upstream-Status: Backport [https://github.com/bluez/bluez/commit/f00d5546c9e989dd68ce0de0190cd0e043b0f1f5] | ||
12 | --- | ||
13 | tools/btmgmt.c | 2 +- | ||
14 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/tools/btmgmt.c b/tools/btmgmt.c | ||
17 | index 9b7f851bd8..436c2bb21f 100644 | ||
18 | --- a/tools/btmgmt.c | ||
19 | +++ b/tools/btmgmt.c | ||
20 | @@ -51,8 +51,8 @@ int main(int argc, char *argv[]) | ||
21 | return EXIT_FAILURE; | ||
22 | } | ||
23 | |||
24 | - bt_shell_attach(fileno(stdin)); | ||
25 | mgmt_set_index(index_option); | ||
26 | + bt_shell_attach(fileno(stdin)); | ||
27 | status = bt_shell_run(); | ||
28 | |||
29 | mgmt_remove_submenu(); | ||