From 2d2eb62fa0a0d8ed7605c395d67cc616a5efbe92 Mon Sep 17 00:00:00 2001 From: zakorgyula Date: Tue, 26 Jul 2016 14:29:23 +0200 Subject: [PATCH] WebBluetooth Specification Change --- components/script/dom/bluetoothremotegattcharacteristic.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/components/script/dom/bluetoothremotegattcharacteristic.rs b/components/script/dom/bluetoothremotegattcharacteristic.rs index e3e17b4a0f9..8c520d7d4ca 100644 --- a/components/script/dom/bluetoothremotegattcharacteristic.rs +++ b/components/script/dom/bluetoothremotegattcharacteristic.rs @@ -195,6 +195,12 @@ impl BluetoothRemoteGATTCharacteristicMethods for BluetoothRemoteGATTCharacteris if !self.Service().Device().Gatt().Connected() { return Err(Network) } + + if !(self.Properties().Write() || + self.Properties().WriteWithoutResponse() || + self.Properties().AuthenticatedSignedWrites()) { + return Err(NotSupported) + } let (sender, receiver) = ipc::channel().unwrap(); self.get_bluetooth_thread().send( BluetoothMethodMsg::WriteValue(self.get_instance_id(), value, sender)).unwrap();