Skip to content
Snippets Groups Projects
Commit 3f8868e8 authored by Srinivasan Ramasubramanian's avatar Srinivasan Ramasubramanian
Browse files

Remove invalid attachments before sending it for comparison in attachment point update logic.

parent 4031b33b
No related branches found
No related tags found
No related merge requests found
......@@ -103,6 +103,16 @@ public class Device implements IDevice {
List<AttachmentPoint>oldAP =
new ArrayList<AttachmentPoint>(attachmentPoints);
// Remove invalid attachment points before sorting.
List<AttachmentPoint>tempAP =
new ArrayList<AttachmentPoint>();
for(AttachmentPoint ap: oldAP) {
if (deviceManager.isValidAttachmentPoint(ap.getSw(), ap.getPort())){
tempAP.add(ap);
}
}
oldAP = tempAP;
Collections.sort(oldAP, deviceManager.apComparator);
// Map of attachment point by L2 domain Id.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment