Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
floodlight
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
croft1
floodlight
Commits
c48fcd14
Commit
c48fcd14
authored
12 years ago
by
Sudeep Modi
Browse files
Options
Downloads
Patches
Plain Diff
Use a set instead of a list to disallow duplicate entries for ignoring MAC
parent
b80a8154
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/main/java/net/floodlightcontroller/linkdiscovery/internal/LinkDiscoveryManager.java
+4
-4
4 additions, 4 deletions
...ntroller/linkdiscovery/internal/LinkDiscoveryManager.java
with
4 additions
and
4 deletions
src/main/java/net/floodlightcontroller/linkdiscovery/internal/LinkDiscoveryManager.java
+
4
−
4
View file @
c48fcd14
...
...
@@ -250,7 +250,7 @@ public class LinkDiscoveryManager implements IOFMessageListener,
long
baseMAC
;
int
ignoreBits
;
}
protected
Lis
t
<
MACRange
>
ignoreMAC
Lis
t
;
protected
Se
t
<
MACRange
>
ignoreMAC
Se
t
;
/**
* Get the LLDP sending period in seconds.
...
...
@@ -2063,7 +2063,7 @@ public class LinkDiscoveryManager implements IOFMessageListener,
this
.
evHistTopologySwitch
=
new
EventHistory
<
EventHistoryTopologySwitch
>(
EVENT_HISTORY_SIZE
);
this
.
evHistTopologyLink
=
new
EventHistory
<
EventHistoryTopologyLink
>(
EVENT_HISTORY_SIZE
);
this
.
evHistTopologyCluster
=
new
EventHistory
<
EventHistoryTopologyCluster
>(
EVENT_HISTORY_SIZE
);
this
.
ignoreMAC
Lis
t
=
new
ArrayLis
t
<
MACRange
>();
this
.
ignoreMAC
Se
t
=
new
HashSe
t
<
MACRange
>();
}
@Override
...
...
@@ -2332,11 +2332,11 @@ public class LinkDiscoveryManager implements IOFMessageListener,
MACRange
range
=
new
MACRange
();
range
.
baseMAC
=
mac
;
range
.
ignoreBits
=
ignoreBits
;
ignoreMAC
Lis
t
.
add
(
range
);
ignoreMAC
Se
t
.
add
(
range
);
}
private
boolean
ignorePacketInFromSource
(
long
srcMAC
)
{
Iterator
<
MACRange
>
it
=
ignoreMAC
Lis
t
.
iterator
();
Iterator
<
MACRange
>
it
=
ignoreMAC
Se
t
.
iterator
();
while
(
it
.
hasNext
())
{
MACRange
range
=
it
.
next
();
long
mask
=
~
0
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment