Skip to content

Commit

Permalink
free commissionee device if pairing fails
Browse files Browse the repository at this point in the history
  • Loading branch information
pan-apple committed Nov 9, 2021
1 parent 1b69687 commit a9bf97a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/controller/CHIPDeviceController.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -973,6 +973,12 @@ void DeviceCommissioner::OnSessionEstablishmentError(CHIP_ERROR err)
}

RendezvousCleanup(err);

if (mDeviceBeingCommissioned != nullptr)
{
ReleaseCommissioneeDevice(mDeviceBeingCommissioned);
mDeviceBeingCommissioned = nullptr;
}
}

void DeviceCommissioner::OnSessionEstablished()
Expand Down

0 comments on commit a9bf97a

Please sign in to comment.