ofproto-dpif: Destroy facets on ofproto removal.
authorEthan Jackson <ethan@nicira.com>
Wed, 4 Sep 2013 16:27:31 +0000 (09:27 -0700)
committerBen Pfaff <blp@nicira.com>
Wed, 4 Sep 2013 20:09:37 +0000 (13:09 -0700)
commit15720dffed5aa12ae133e8f007c6d4145f6dd919
tree62be55563a3e5ec472cf6a088cb465fdafb46b8f
parent416e09ef5e61fd44b21d82187f167d6690837bba
ofproto-dpif: Destroy facets on ofproto removal.

Facets maintain a pointer to their owning ofproto-dpif, and therefore
when an ofproto-dpif is destroyed all of their child facets should be
destroyed along with it.  If they aren't, it's possible a subfacet
looked up in the dpif-backer could access it's parent facet and
therefore a defunct parent ofproto causing a segmentation fault.

Bug #19421.
Bug #19423.
Diagnosed-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: Ethan Jackson <ethan@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
ofproto/ofproto-dpif.c