Skip to content

Commit

Permalink
fix unbind
Browse files Browse the repository at this point in the history
  • Loading branch information
gjc13 committed Jan 18, 2022
1 parent a9aafb3 commit d93edf7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/app/clusters/bindings/BindingManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,11 +118,12 @@ CHIP_ERROR BindingManager::LastUnicastBindingRemoved(FabricIndex fabric, NodeId
VerifyOrReturnError(fabricInfo != nullptr, CHIP_ERROR_NOT_FOUND);
PeerId peer = fabricInfo->GetPeerIdForNode(node);
PendingNotificationEntry * entry = mPendingNotificationMap.FindEntry(peer);

VerifyOrReturnError(entry != nullptr, CHIP_ERROR_NOT_FOUND);
if (entry)
{
mPendingNotificationMap.RemoveEntry(entry);
}

mAppServer->GetCASESessionManager()->ReleaseSession(peer);
mPendingNotificationMap.RemoveEntry(entry);
return CHIP_NO_ERROR;
}

Expand Down

0 comments on commit d93edf7

Please sign in to comment.