| Index: device/bluetooth/dbus/bluetooth_gatt_application_service_provider_impl.cc
|
| diff --git a/device/bluetooth/dbus/bluetooth_gatt_application_service_provider_impl.cc b/device/bluetooth/dbus/bluetooth_gatt_application_service_provider_impl.cc
|
| index 41c3cc62ca5a84eede7a3f719f28c10d17710c96..873ea3202eefddf8adf1924caa9a09ca448db264 100644
|
| --- a/device/bluetooth/dbus/bluetooth_gatt_application_service_provider_impl.cc
|
| +++ b/device/bluetooth/dbus/bluetooth_gatt_application_service_provider_impl.cc
|
| @@ -22,7 +22,8 @@ BluetoothGattApplicationServiceProviderImpl::
|
| weak_ptr_factory_(this) {
|
| VLOG(1) << "Creating Bluetooth GATT application: " << object_path_.value();
|
| DCHECK(object_path_.IsValid());
|
| - DCHECK(bus_);
|
| + if (!bus_)
|
| + return;
|
|
|
| exported_object_ = bus_->GetExportedObject(object_path_);
|
|
|
| @@ -35,9 +36,7 @@ BluetoothGattApplicationServiceProviderImpl::
|
| base::Bind(&BluetoothGattApplicationServiceProviderImpl::OnExported,
|
| weak_ptr_factory_.GetWeakPtr()));
|
|
|
| - BluetoothGattApplicationServiceProvider::CreateAttributeServiceProviders(
|
| - bus, services, &service_providers_, &characteristic_providers_,
|
| - &descriptor_providers_);
|
| + CreateAttributeServiceProviders(bus, services);
|
| }
|
|
|
| BluetoothGattApplicationServiceProviderImpl::
|
| @@ -47,16 +46,6 @@ BluetoothGattApplicationServiceProviderImpl::
|
| bus_->UnregisterExportedObject(object_path_);
|
| }
|
|
|
| -BluetoothGattApplicationServiceProviderImpl::
|
| - BluetoothGattApplicationServiceProviderImpl(
|
| - const dbus::ObjectPath& object_path)
|
| - : origin_thread_id_(base::PlatformThread::CurrentId()),
|
| - bus_(nullptr),
|
| - object_path_(object_path),
|
| - weak_ptr_factory_(this) {
|
| - VLOG(1) << "Creating Fake Bluetooth GATT application service provider.";
|
| -}
|
| -
|
| bool BluetoothGattApplicationServiceProviderImpl::OnOriginThread() {
|
| return base::PlatformThread::CurrentId() == origin_thread_id_;
|
| }
|
|
|