diff --git a/packages/SettingsLib/src/com/android/settingslib/bluetooth/LocalBluetoothProfileManager.java b/packages/SettingsLib/src/com/android/settingslib/bluetooth/LocalBluetoothProfileManager.java index 0e7b79ba297ab49401fee181bce135b1a2c6fbc0..119aef6da12ef39b53f855ad58662fde86901624 100644 --- a/packages/SettingsLib/src/com/android/settingslib/bluetooth/LocalBluetoothProfileManager.java +++ b/packages/SettingsLib/src/com/android/settingslib/bluetooth/LocalBluetoothProfileManager.java @@ -136,7 +136,7 @@ public class LocalBluetoothProfileManager { /** * create profile instance according to bluetooth supported profile list */ - void updateLocalProfiles() { + synchronized void updateLocalProfiles() { List<Integer> supportedList = BluetoothAdapter.getDefaultAdapter().getSupportedProfiles(); if (CollectionUtils.isEmpty(supportedList)) { if (DEBUG) Log.d(TAG, "supportedList is null");