Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
OVN: Don't let peers be set to "<error>" on port bindings.
There are a couple of places in ovn-northd that set the "peer" option on certain ports to "<error>" in certain cases. In every case where a peer is looked up on a port binding, the code performs a NULL check in order to ensure a peer exists. None check for the "<error>" string. They assume that the presence of a peer string means a peer is defined and all is well. In the past (OVS 2.6 series), this sometimes led to patch ports being created in ovs that had names like "patch-ro-to-<error>". This particular problem resolved itself in OVS 2.7 since such patch ports were no longer automatically created. However, by naming the peer "<error>" the seeds are still sown for similar issues to occur. The solution this patch suggests is to no longer set the "peer" option on a port binding to "<error>". Instead, if no peer can be set, then we set no peer. Since other code is already equipped to deal with this, this poses no problem. Signed-off-by: Mark Michelson <[email protected]> Signed-off-by: Ben Pfaff <[email protected]>
- Loading branch information