Fixes: 1b1d2e6daa56 ("ovsdb: Introduce experimental support for clustered
databases.")
Signed-off-by: Dumitru Ceara <[email protected]>
---
ovsdb/ovsdb-server.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/ovsdb/ovsdb-server.c b/ovsdb/ovsdb-server.c
index b09232c654..2df5bc4e74 100644
--- a/ovsdb/ovsdb-server.c
+++ b/ovsdb/ovsdb-server.c
@@ -676,9 +676,6 @@ open_db(struct server_config *config, const char *filename)
return error;
}
- db = xzalloc(sizeof *db);
- db->filename = xstrdup(filename);
-
struct ovsdb_schema *schema;
if (ovsdb_storage_is_clustered(storage)) {
schema = NULL;
@@ -691,6 +688,9 @@ open_db(struct server_config *config, const char *filename)
}
ovs_assert(schema && !txn_json);
}
+
+ db = xzalloc(sizeof *db);
+ db->filename = xstrdup(filename);
db->db = ovsdb_create(schema, storage);
ovsdb_jsonrpc_server_add_db(config->jsonrpc, db->db);
--
2.27.0
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev