ofproto-dpif: Fix memory leak of mirrors in bundle_destroy().
authorBen Pfaff <blp@nicira.com>
Thu, 22 Jan 2015 05:08:12 +0000 (21:08 -0800)
committerBen Pfaff <blp@nicira.com>
Thu, 22 Jan 2015 05:11:06 +0000 (21:11 -0800)
The mirrors are added in bundle_set() with 'bundle' as aux so they must
be removed with the same aux, but the call used 'bundle->aux' instead.

Reported-by: Sabyasachi Sengupta <Sabyasachi.Sengupta@alcatel-lucent.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
AUTHORS
ofproto/ofproto-dpif.c

diff --git a/AUTHORS b/AUTHORS
index 8db4026..54da347 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -263,6 +263,7 @@ Simon Jouet             simon.jouet@gmail.com
 Spiro Kourtessis        spiro@vmware.com
 Sridhar Samudrala       samudrala.sridhar@gmail.com
 Srini Seetharaman       seethara@stanford.edu
+Sabyasachi Sengupta     Sabyasachi.Sengupta@alcatel-lucent.com
 Stephen Hemminger       shemminger@vyatta.com
 Stephen Finucane        stephen.finucane@intel.com
 Suganya Ramachandran    suganyar@vmware.com
index dc555dd..c18ed32 100644 (file)
@@ -2309,7 +2309,7 @@ bundle_destroy(struct ofbundle *bundle)
     }
 
     ofproto = bundle->ofproto;
-    mbridge_unregister_bundle(ofproto->mbridge, bundle->aux);
+    mbridge_unregister_bundle(ofproto->mbridge, bundle);
 
     ovs_rwlock_wrlock(&xlate_rwlock);
     xlate_bundle_remove(bundle);