From 5637abd0289217c705a4add6abe20494ed3e0bf6 Mon Sep 17 00:00:00 2001 From: Sergey Vasiliev Date: Fri, 18 Jun 2021 18:08:07 +0000 Subject: [PATCH] Fix chip-tool crash in case of commissioning ethernet device. Need to figure out what SetupNetwork() should do in case of Ethernet, for now do nothing --- examples/chip-tool/commands/pairing/PairingCommand.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/chip-tool/commands/pairing/PairingCommand.cpp b/examples/chip-tool/commands/pairing/PairingCommand.cpp index e96897106c608d..21fc0cc3d033b9 100644 --- a/examples/chip-tool/commands/pairing/PairingCommand.cpp +++ b/examples/chip-tool/commands/pairing/PairingCommand.cpp @@ -170,11 +170,11 @@ CHIP_ERROR PairingCommand::SetupNetwork() switch (mNetworkType) { case PairingNetworkType::None: + case PairingNetworkType::Ethernet: // Nothing to do SetCommandExitStatus(err == CHIP_NO_ERROR); break; case PairingNetworkType::WiFi: - case PairingNetworkType::Ethernet: case PairingNetworkType::Thread: err = GetExecContext()->commissioner->GetDevice(mRemoteId, &mDevice); VerifyOrExit(err == CHIP_NO_ERROR, ChipLogError(chipTool, "Setup failure! No pairing for device: %" PRIu64, mRemoteId));