Fix race condition between starting of service and getting the Profile Proxy.
Incoming A2DP connections were not working. Change-Id: I5a3322ddb39b2512495b4cd2e35593da0f605087
This commit is contained in:
@@ -215,6 +215,7 @@ class ServerThread extends Thread {
|
||||
bluetoothA2dp = new BluetoothA2dpService(context, bluetooth);
|
||||
ServiceManager.addService(BluetoothA2dpService.BLUETOOTH_A2DP_SERVICE,
|
||||
bluetoothA2dp);
|
||||
bluetooth.initAfterA2dpRegistration();
|
||||
|
||||
int bluetoothOn = Settings.Secure.getInt(mContentResolver,
|
||||
Settings.Secure.BLUETOOTH_ON, 0);
|
||||
@@ -438,7 +439,7 @@ class ServerThread extends Thread {
|
||||
} catch (Throwable e) {
|
||||
Slog.e(TAG, "Failure starting Recognition Service", e);
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
Slog.i(TAG, "DiskStats Service");
|
||||
ServiceManager.addService("diskstats", new DiskStatsService(context));
|
||||
|
||||
Reference in New Issue
Block a user