[ovs-dev] [PATCH] ovsdb-server: Fix memory leak in ovsdb_server_get_sync_exclude_tables().

Ben Pfaff blp at ovn.org
Fri Sep 9 04:22:21 UTC 2016


Fixes: 3109b4e127fa ("ovsdb: Add blacklist_tables")
Signed-off-by: Ben Pfaff <blp at ovn.org>
---
 ovsdb/ovsdb-server.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/ovsdb/ovsdb-server.c b/ovsdb/ovsdb-server.c
index c33ab86..0e3f9ac 100644
--- a/ovsdb/ovsdb-server.c
+++ b/ovsdb/ovsdb-server.c
@@ -1215,7 +1215,9 @@ ovsdb_server_get_sync_exclude_tables(struct unixctl_conn *conn,
                                      const char *argv[] OVS_UNUSED,
                                      void *arg_ OVS_UNUSED)
 {
-    unixctl_command_reply(conn, get_blacklist_tables());
+    char *reply = get_blacklist_tables();
+    unixctl_command_reply(conn, reply);
+    free(reply);
 }
 
 static void
-- 
2.1.3




More information about the dev mailing list