summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--device/bluetooth/bluez/bluetooth_service_attribute_value_bluez.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/device/bluetooth/bluez/bluetooth_service_attribute_value_bluez.cc b/device/bluetooth/bluez/bluetooth_service_attribute_value_bluez.cc
index c66b95332f..e9d61a8250 100644
--- a/device/bluetooth/bluez/bluetooth_service_attribute_value_bluez.cc
+++ b/device/bluetooth/bluez/bluetooth_service_attribute_value_bluez.cc
@@ -33,6 +33,11 @@ BluetoothServiceAttributeValueBlueZ::BluetoothServiceAttributeValueBlueZ(
this->type_ = attribute.type_;
this->size_ = attribute.size_;
+ if (attribute.type_ == NULLTYPE) {
+ this->value_ = base::Value::CreateNullValue();
+ return;
+ }
+
if (attribute.type_ != SEQUENCE) {
this->value_ = base::WrapUnique(attribute.value_->DeepCopy());
return;