Skip to content
Snippets Groups Projects
Commit 7036a327 authored by abat's avatar abat
Browse files

Merge into master from pull request #65:

Only remove flows on move when the cookie is from forwarding (https://github.com/floodlight/floodlight/pull/65)
parents fedaf81b b22e2f6e
No related branches found
No related tags found
No related merge requests found
......@@ -403,11 +403,14 @@ public abstract class ForwardingBase implements IOFMessageListener, IDeviceManag
OFMatch match = new OFMatch();
match.setDataLayerDestination(device.getDataLayerAddress());
match.setWildcards(OFMatch.OFPFW_ALL ^ OFMatch.OFPFW_DL_DST);
long cookie =
AppCookie.makeCookie(FORWARDING_APP_ID, 0);
OFMessage fm = ((OFFlowMod) floodlightProvider.getOFMessageFactory()
.getMessage(OFType.FLOW_MOD))
.setCommand(OFFlowMod.OFPFC_DELETE)
.setOutPort((short) OFPort.OFPP_NONE.getValue())
.setMatch(match)
.setCookie(cookie)
.setLength(U16.t(OFFlowMod.MINIMUM_LENGTH));
// Flush to all switches
......
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