Skip to content

Commit 16e23d3

Browse files
authored
Fix fabric-bridge-app crash (project-chip#34893)
1 parent 95ff33b commit 16e23d3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

examples/fabric-bridge-app/linux/RpcServer.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,11 @@ pw::Status FabricBridge::AddSynchronizedDevice(const chip_rpc_SynchronizedDevice
118118
return pw::Status::Unknown();
119119
}
120120

121+
BridgedDevice * addedDevice = BridgeDeviceMgr().GetDeviceByNodeId(nodeId);
122+
VerifyOrDie(addedDevice);
123+
121124
CHIP_ERROR err = EcosystemInformation::EcosystemInformationServer::Instance().AddEcosystemInformationClusterToEndpoint(
122-
device->GetEndpointId());
125+
addedDevice->GetEndpointId());
123126
VerifyOrDie(err == CHIP_NO_ERROR);
124127

125128
return pw::OkStatus();

0 commit comments

Comments
 (0)