bridge: Clear out all Interface fields when an interface cannot be created.
authorBen Pfaff <blp@nicira.com>
Wed, 28 Sep 2011 16:36:13 +0000 (09:36 -0700)
committerBen Pfaff <blp@nicira.com>
Thu, 29 Sep 2011 16:18:12 +0000 (09:18 -0700)
commit3fc5a86ab3e7168993a51ed3e71e25eda40f71fe
treeaeb4b012e9c9a5f33bc306404cc82a060c678bea
parente084518ad4e7ce349d23ddda7c74ea8a57ca0f56
bridge: Clear out all Interface fields when an interface cannot be created.

When an Interface record is invalid (for example, when the interface that
it specifies does not exist and cannot be created), ovs-vswitchd would
leave any pre-existing data in its columns, except that it would set the
ofport column to -1 to indicate the error.  This was sometimes confusing
because, for example, the lacp_current field could still be set to "true"
if LACP has previously been active and up-to-date.

This commit changes ovs-vswitchd to reset all such data to its default
values when an interface is invalid.

Bug #7450.
Reported-by: Duffie Cooley <dcooley@nicira.com>
Bug #7491.
Reported-by: Ethan Jackson <ethan@nicira.com>
Release Notes #7500.
Reported-by: Keith Amidon <keith@nicira.com>
AUTHORS
vswitchd/bridge.c