From: Ben Pfaff Date: Thu, 31 Mar 2011 21:12:57 +0000 (-0700) Subject: bridge: Destroy ofproto before deleting dpif. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d6ab93e9dcd91119ea9a1a843c1bb35e6754706;p=openvswitch bridge: Destroy ofproto before deleting dpif. Otherwise the ofproto's attempt to flush flows from the dpif will fail with an error, causing a spurious log message. --- diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c index bf89778c..72091a29 100644 --- a/vswitchd/bridge.c +++ b/vswitchd/bridge.c @@ -1690,13 +1690,13 @@ bridge_destroy(struct bridge *br) port_destroy(port); } list_remove(&br->node); + ofproto_destroy(br->ofproto); error = dpif_delete(br->dpif); if (error && error != ENOENT) { VLOG_ERR("failed to delete %s: %s", dpif_name(br->dpif), strerror(error)); } dpif_close(br->dpif); - ofproto_destroy(br->ofproto); mac_learning_destroy(br->ml); hmap_destroy(&br->ifaces); hmap_destroy(&br->ports);