Skip to content

Commit

Permalink
Deactivate mirror session only when session status is true in updateL…
Browse files Browse the repository at this point in the history
…agMember (sonic-net#1666)

Deactivate mirror session only when the status is true in updateLagMember
  • Loading branch information
shi-su authored and raphaelt-nvidia committed Oct 5, 2021
1 parent 4c4a3a9 commit 8d646a9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion orchagent/mirrororch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1342,7 +1342,10 @@ void MirrorOrch::updateLagMember(const LagMemberUpdate& update)
// If LAG is empty, deactivate session
if (update.lag.m_members.empty())
{
deactivateSession(name, session);
if (session.status)
{
deactivateSession(name, session);
}
session.neighborInfo.portId = SAI_OBJECT_TYPE_NULL;
}
// Switch to a new member of the LAG
Expand Down

0 comments on commit 8d646a9

Please sign in to comment.