| Index: chromeos/dbus/fake_bluetooth_profile_manager_client.cc
|
| diff --git a/chromeos/dbus/fake_bluetooth_profile_manager_client.cc b/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
|
| index 2839ddd8cbbc27725dd517b920e900a649d5f816..8d702214d765a06a55f2820b24abbb53cf738d41 100644
|
| --- a/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
|
| +++ b/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
|
| @@ -23,6 +23,8 @@ const char FakeBluetoothProfileManagerClient::kL2capUuid[] =
|
| "4d995052-33cc-4fdf-b446-75f32942a076";
|
| const char FakeBluetoothProfileManagerClient::kRfcommUuid[] =
|
| "3f6d6dbf-a6ad-45fc-9653-47dc912ef70e";
|
| +const char FakeBluetoothProfileManagerClient::kUnregisterableUuid[] =
|
| + "00000000-0000-0000-0000-000000000000";
|
|
|
| FakeBluetoothProfileManagerClient::FakeBluetoothProfileManagerClient() {
|
| }
|
| @@ -41,6 +43,14 @@ void FakeBluetoothProfileManagerClient::RegisterProfile(
|
| const ErrorCallback& error_callback) {
|
| VLOG(1) << "RegisterProfile: " << profile_path.value() << ": " << uuid;
|
|
|
| + if (uuid == kUnregisterableUuid) {
|
| + base::MessageLoop::current()->PostTask(
|
| + FROM_HERE, base::Bind(error_callback,
|
| + bluetooth_profile_manager::kErrorInvalidArguments,
|
| + "Can't register this UUID"));
|
| + return;
|
| + }
|
| +
|
| // check options for channel & psm
|
|
|
| ServiceProviderMap::iterator iter = service_provider_map_.find(profile_path);
|
|
|