aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Wang <alexw@nicira.com>2013-07-22 18:15:49 -0700
committerBen Pfaff <blp@nicira.com>2013-09-05 13:11:01 -0700
commit6a3d683b9bb70636442588badb39486658fdeafa (patch)
tree62f164f49d6e6a2c09c0ad97d1b4bb8ddfa82f9d
parentb53d1713ad7ce865c47e3fb8421f27c6a0dcbb9c (diff)
vlan-splinter: Fix inverted logic bug.v1.9.3
When "other-config:enable-vlan-splinters=true" is set, the existing vlans with ip address must be retained. The bug actually does the opposite and retains the vlans without ip address. This commit fixes it. Reported-by: Roman Sokolkov <rsokolkov@gmail.com> Signed-off-by: Alex Wang <alexw@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
-rw-r--r--AUTHORS1
-rw-r--r--vswitchd/bridge.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/AUTHORS b/AUTHORS
index 92ec1fb79..44fa779c8 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -165,6 +165,7 @@ Ramana Reddy gtvrreddy@gmail.com
Rob Sherwood rob.sherwood@bigswitch.com
Roger Leigh rleigh@codelibre.net
Rogério Vinhal Nunes
+Roman Sokolkov rsokolkov@gmail.com
Scott Hendricks shendricks@nicira.com
Sean Brady sbrady@gtfservices.com
Sebastian Andrzej Siewior sebastian@breakpoint.cc
diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c
index a481f061a..96bd99749 100644
--- a/vswitchd/bridge.c
+++ b/vswitchd/bridge.c
@@ -3702,10 +3702,10 @@ collect_splinter_vlans(const struct ovsrec_open_vswitch *ovs_cfg)
if (!netdev_open(vlan_dev->name, "system", &netdev)) {
if (!netdev_get_in4(netdev, NULL, NULL) ||
!netdev_get_in6(netdev, NULL)) {
- vlandev_del(vlan_dev->name);
- } else {
/* It has an IP address configured, so we don't own
* it. Don't delete it. */
+ } else {
+ vlandev_del(vlan_dev->name);
}
netdev_close(netdev);
}