commit | 25e077e9cd8e1c74f82088b6434bc637f65e11c3 | [log] [tgz] |
---|---|---|
author | abat <abat@bigswitch.com> | Mon Apr 14 22:46:34 2014 -0700 |
committer | abat <abat@bigswitch.com> | Mon Apr 14 22:46:34 2014 -0700 |
tree | e15f6c8b0a2f1ced80c6c0db5e9e2f2d029c7aa6 | |
parent | eddc92a158432e3689f8189d2046210013216b71 [diff] | |
parent | dd53516f333e283f26d1a26a73c44303d3d59638 [diff] |
Merge into master from pull request #248: update VlanVid.ofVlan to accept NO_MASK (https://github.com/floodlight/loxigen/pull/248)
diff --git a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/VlanVid.java b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/VlanVid.java index 2e675d4..ee605de 100644 --- a/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/VlanVid.java +++ b/java_gen/pre-written/src/main/java/org/projectfloodlight/openflow/types/VlanVid.java
@@ -33,6 +33,8 @@ } public static VlanVid ofVlan(int vid) { + if (vid == NO_MASK.vid) + return NO_MASK; if ((vid & VALIDATION_MASK) != vid) throw new IllegalArgumentException(String.format("Illegal VLAN value: %x", vid)); return new VlanVid((short) vid);