Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ovn-controller: avoid crash when vswitchd connection is lost
When ovs-vswitchd has dropped its connection to ovn-controller, rconn_get_version() will return -1. OpenFlow messages built by ofctrl_put() in this condition will have an invalid OpenFlow version value of 255, which eventually leads to ovn-controller crashing due to an assertion failure in raw_instance_get(). Avoid this crash by improving the ofctrl_can_put() test to ensure that the negotiated version is available. (Note that checking rconn_is_connected() would not be sufficient since rconn S_IDLE state is considered "connected" but version negotiation is not necessarily complete). Signed-off-by: Lance Richardson <[email protected]> Signed-off-by: Ben Pfaff <[email protected]>
- Loading branch information