Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1854)

Unified Diff: components/arc/bluetooth/arc_bluetooth_bridge.cc

Issue 2270613002: arc: bluetooth: Always acquire a NotifySession (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/arc/bluetooth/arc_bluetooth_bridge.cc
diff --git a/components/arc/bluetooth/arc_bluetooth_bridge.cc b/components/arc/bluetooth/arc_bluetooth_bridge.cc
index 95a9f481e0f2541367c0f368ada188c8d8ca5014..3bc0d3092fdf3fd517879475d79e6276c6878fc8 100644
--- a/components/arc/bluetooth/arc_bluetooth_bridge.cc
+++ b/components/arc/bluetooth/arc_bluetooth_bridge.cc
@@ -1003,11 +1003,6 @@ void ArcBluetoothBridge::RegisterForGattNotification(
return;
}
- if (characteristic->IsNotifying()) {
- callback.Run(mojom::BluetoothGattStatus::GATT_SUCCESS);
- return;
- }
-
characteristic->StartNotifySession(
base::Bind(&ArcBluetoothBridge::OnGattNotifyStartDone,
weak_factory_.GetWeakPtr(), callback,
@@ -1030,11 +1025,6 @@ void ArcBluetoothBridge::DeregisterForGattNotification(
return;
}
- if (!characteristic->IsNotifying()) {
- callback.Run(mojom::BluetoothGattStatus::GATT_SUCCESS);
- return;
- }
-
std::string char_id_str = characteristic->GetIdentifier();
std::unique_ptr<BluetoothGattNotifySession> notify =
std::move(notification_session_[char_id_str]);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698