From 937ad5999f2b7dd271d700ab6bf87cb6d15701cc Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Wed, 2 Mar 2022 14:10:30 -0500 Subject: [PATCH 1/2] Stop processing Address change notifications within darwin chip device controller --- src/darwin/Framework/CHIP/CHIPDeviceController.mm | 2 +- src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.h | 5 +---- src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm | 5 ----- 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/darwin/Framework/CHIP/CHIPDeviceController.mm b/src/darwin/Framework/CHIP/CHIPDeviceController.mm index dce0716239c729..24ec342d232498 100644 --- a/src/darwin/Framework/CHIP/CHIPDeviceController.mm +++ b/src/darwin/Framework/CHIP/CHIPDeviceController.mm @@ -198,7 +198,7 @@ - (BOOL)startup:(_Nullable id)storageDelegate params.fabricStorage = _fabricStorage; params.fabricIndependentStorage = _persistentStorageDelegateBridge; commissionerParams.storageDelegate = _persistentStorageDelegateBridge; - commissionerParams.deviceAddressUpdateDelegate = _pairingDelegateBridge; + commissionerParams.deviceAddressUpdateDelegate = nullptr; commissionerParams.pairingDelegate = _pairingDelegateBridge; commissionerParams.operationalCredentialsDelegate = _operationalCredentialsDelegate; diff --git a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.h b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.h index 85dbf70eb8272a..7763219114b3ed 100644 --- a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.h +++ b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.h @@ -23,8 +23,7 @@ NS_ASSUME_NONNULL_BEGIN -class CHIPDevicePairingDelegateBridge : public chip::Controller::DevicePairingDelegate, - public chip::Controller::DeviceAddressUpdateDelegate +class CHIPDevicePairingDelegateBridge : public chip::Controller::DevicePairingDelegate { public: CHIPDevicePairingDelegateBridge(); @@ -40,8 +39,6 @@ class CHIPDevicePairingDelegateBridge : public chip::Controller::DevicePairingDe void OnCommissioningComplete(chip::NodeId deviceId, CHIP_ERROR error) override; - void OnAddressUpdateComplete(chip::NodeId nodeId, CHIP_ERROR error) override; - private: id mDelegate; dispatch_queue_t mQueue; diff --git a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm index c0a69fe17cb98d..7fde6b9462f490 100644 --- a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm @@ -110,8 +110,3 @@ } } -void CHIPDevicePairingDelegateBridge::OnAddressUpdateComplete(chip::NodeId nodeId, CHIP_ERROR error) -{ - // Todo, is there any benefit of exposing this anymore? - NSLog(@"OnAddressUpdateComplete. Status %s", chip::ErrorStr(error)); -} From 8838e7c705b4de5a46b35b40782b9670d96b0968 Mon Sep 17 00:00:00 2001 From: Andrei Litvin Date: Wed, 2 Mar 2022 14:10:46 -0500 Subject: [PATCH 2/2] Restyle --- src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm | 1 - 1 file changed, 1 deletion(-) diff --git a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm index 7fde6b9462f490..e026553e3c080d 100644 --- a/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm +++ b/src/darwin/Framework/CHIP/CHIPDevicePairingDelegateBridge.mm @@ -109,4 +109,3 @@ } } } -