From: Wootak Jung Date: Tue, 24 Nov 2020 01:57:39 +0000 (+0900) Subject: [Bluetooth][Non-ACR] Fix svace issue (#2270) (#2278) X-Git-Tag: submit/tizen_6.0/20201125.005231~1^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1dadb48f9fbe1d0ad60409f6f46c4bb5b2d46ecf;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git [Bluetooth][Non-ACR] Fix svace issue (#2270) (#2278) Signed-off-by: Wootak Jung --- diff --git a/src/Tizen.Network.Bluetooth/Tizen.Network.Bluetooth/BluetoothGattImpl.cs b/src/Tizen.Network.Bluetooth/Tizen.Network.Bluetooth/BluetoothGattImpl.cs index 4e8f288..559a14b 100644 --- a/src/Tizen.Network.Bluetooth/Tizen.Network.Bluetooth/BluetoothGattImpl.cs +++ b/src/Tizen.Network.Bluetooth/Tizen.Network.Bluetooth/BluetoothGattImpl.cs @@ -371,7 +371,10 @@ namespace Tizen.Network.Bluetooth } BluetoothGattCharacteristic Characteristic = BluetoothGattCharacteristicImpl.CreateBluetoothGattGattCharacteristic(attributeHandle, uuid); - Characteristic.SetParent(service); + if (Characteristic != null) + { + Characteristic.SetParent(service); + } return Characteristic; } @@ -532,7 +535,10 @@ namespace Tizen.Network.Bluetooth return null; } BluetoothGattDescriptor descriptor = BluetoothGattDescriptorImpl.CreateBluetoothGattDescriptor(handle, uuid); - descriptor.SetParent(characteristic); + if (descriptor != null) + { + descriptor.SetParent(characteristic); + } return descriptor; }