diff options
author | Matadeen Mishra <matade@codeaurora.org> | 2015-08-21 09:47:05 +0530 |
---|---|---|
committer | Linux Build Service Account <lnxbuild@localhost> | 2015-10-06 03:22:00 -0600 |
commit | fada44256f77be2e7cdf1b6089c15c4b08a76046 (patch) | |
tree | 3a19278722436dd7dfc10c723f1feacb1632754b /utils | |
parent | c50610c030fc7b0bd547750a9851b772d836391a (diff) | |
download | android_system_bt-fada44256f77be2e7cdf1b6089c15c4b08a76046.tar.gz android_system_bt-fada44256f77be2e7cdf1b6089c15c4b08a76046.tar.bz2 android_system_bt-fada44256f77be2e7cdf1b6089c15c4b08a76046.zip |
BT: Fixed Static Analysis Issues
- This fix avoids NULL pointer dereferences,
Array Index Out of Bounds Exceptions
and Banned funciton in the bluedroid code
space of Bluetooth.
CRs-Fixed: 890309, 890321
Change-Id: I24ae794ee01b65b5ab15c73cd82677b0481910ad
Diffstat (limited to 'utils')
-rw-r--r-- | utils/src/bt_utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/utils/src/bt_utils.c b/utils/src/bt_utils.c index 53a53de20..4a73c8057 100644 --- a/utils/src/bt_utils.c +++ b/utils/src/bt_utils.c @@ -123,7 +123,7 @@ void raise_priority_a2dp(tHIGH_PRIORITY_TASK high_task) { g_TaskIdx = high_task; pthread_once(&g_DoSchedulingGroupOnce[g_TaskIdx], check_do_scheduling_group); - if (g_DoSchedulingGroup[g_TaskIdx]) { + if (g_TaskIdx < TASK_HIGH_MAX && g_DoSchedulingGroup[g_TaskIdx]) { // set_sched_policy does not support tid == 0 rc = set_sched_policy(tid, SP_AUDIO_SYS); } |