tizenaudio-policy: Skip bt device that does not have A2DP profile in case of auto... 33/99533/1
authorSangchul Lee <sc11.lee@samsung.com>
Wed, 23 Nov 2016 07:54:02 +0000 (16:54 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Wed, 23 Nov 2016 07:57:26 +0000 (16:57 +0900)
[Version] 5.0.95
[Profile] Common
[Issue Type] bug

Change-Id: I1d44f9f088db98c066b699d9b2d00e069e702572
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
packaging/pulseaudio-modules-tizen.spec
src/module-tizenaudio-policy.c

index a1e674a..3d316a6 100644 (file)
@@ -1,6 +1,6 @@
 Name:             pulseaudio-modules-tizen
 Summary:          Pulseaudio modules for Tizen
-Version:          5.0.94
+Version:          5.0.95
 Release:          0
 Group:            Multimedia/Audio
 License:          LGPL-2.1+
index b51798b..99907d3 100644 (file)
@@ -864,6 +864,8 @@ static pa_hook_result_t route_change_hook_cb(pa_core *c, pa_stream_manager_hook_
                     creation_time = pa_tz_device_get_creation_time(device);
                     pa_log_debug("  -- type[%-16s], subtype[%-5s], direction[0x%x], id[%u], creation_time[%llu]",
                                  dm_device_type, dm_device_subtype, dm_device_direction, dm_device_id, creation_time);
+                    if (pa_streq(device->type, DEVICE_TYPE_BT) && !pa_tz_device_have_profile(device, "a2dp"))
+                        continue;
                     if (pa_streq(device_type, dm_device_type) && IS_AVAILABLE_DIRECTION(data->stream_type, dm_device_direction)) {
                         if (!latest_device || (latest_creation_time <= creation_time)) {
                             latest_device = device;