projects
/
openvswitch
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0ae1bf3
)
rconn_destroy() should close monitoring connections, to avoid a leak.
author
Ben Pfaff
<blp@nicira.com>
Thu, 27 Nov 2008 00:27:21 +0000
(16:27 -0800)
committer
Ben Pfaff
<blp@nicira.com>
Thu, 27 Nov 2008 06:25:39 +0000
(22:25 -0800)
Our current code base never closes an rconn that has a monitoring
connection, so this does not fix any larger problem.
lib/rconn.c
patch
|
blob
|
history
diff --git
a/lib/rconn.c
b/lib/rconn.c
index e610e61a0d5af11692688bdcad860229fca6802c..ba606fb5eaba2ee1881887d024004dff169c1773 100644
(file)
--- a/
lib/rconn.c
+++ b/
lib/rconn.c
@@
-264,10
+264,15
@@
void
rconn_destroy(struct rconn *rc)
{
if (rc) {
+ size_t i;
+
free(rc->name);
vconn_close(rc->vconn);
flush_queue(rc);
queue_destroy(&rc->txq);
+ for (i = 0; i < rc->n_monitors; i++) {
+ vconn_close(rc->monitors[i]);
+ }
free(rc);
}
}