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

Unified Diff: third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp

Issue 2183903002: bluetooth: Reject getPrimaryService(s) if frame is not connected (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@my-origin
Patch Set: Docs Created 4 years, 5 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
Index: third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp
diff --git a/third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp b/third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp
index e717ea2d9ac9385eb3a465496ea9a2978929e4e4..e3ca6e56b2d292739f60d3d445d3ee4075920c14 100644
--- a/third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp
+++ b/third_party/WebKit/Source/modules/bluetooth/BluetoothDevice.cpp
@@ -48,6 +48,7 @@ bool BluetoothDevice::disconnectGATTIfConnected()
{
if (m_gatt->connected()) {
m_gatt->setConnected(false);
+ m_gatt->ClearActiveAlgorithms();
BluetoothSupplement::fromExecutionContext(getExecutionContext())->disconnect(id());
return true;
}
@@ -68,6 +69,7 @@ void BluetoothDevice::dispatchGattServerDisconnected()
{
if (m_gatt->connected()) {
m_gatt->setConnected(false);
+ m_gatt->ClearActiveAlgorithms();
dispatchEvent(Event::createBubble(EventTypeNames::gattserverdisconnected));
}
}

Powered by Google App Engine
This is Rietveld 408576698