ovsdb-server: Fix memory leak.
authorEthan Jackson <ethan@nicira.com>
Thu, 17 Feb 2011 20:52:48 +0000 (12:52 -0800)
committerEthan Jackson <ethan@nicira.com>
Thu, 17 Feb 2011 21:04:49 +0000 (13:04 -0800)
Reported-by: Peter Balland <peter@nicira.com>
Bug #4698.

ovsdb/ovsdb-server.c

index 79fc8f933ca57e8f12773eb5135c2e8c6cc8d4ed..fac78c80785c02472bd8a5e38dc425a6fe621ca5 100644 (file)
@@ -171,7 +171,7 @@ main(int argc, char *argv[])
     }
     ovsdb_jsonrpc_server_destroy(jsonrpc);
     ovsdb_destroy(db);
-    shash_destroy(&remotes);
+    shash_destroy_free_data(&remotes);
     unixctl_server_destroy(unixctl);
 
     if (run_process && process_exited(run_process)) {
@@ -593,7 +593,7 @@ reconfigure_from_db(struct ovsdb_jsonrpc_server *jsonrpc,
         }
     }
     ovsdb_jsonrpc_server_set_remotes(jsonrpc, &resolved_remotes);
-    shash_destroy(&resolved_remotes);
+    shash_destroy_free_data(&resolved_remotes);
 
 #if HAVE_OPENSSL
     /* Configure SSL. */