1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-03 01:18:10 +03:00

ctdb: Add a NULL check to convert_node_map_to_list()

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jennifer Sutton <jsutton@samba.org>
This commit is contained in:
Volker Lendecke 2024-08-20 12:48:20 +02:00
parent 232ab02faf
commit 3cc3329420

View File

@ -106,6 +106,7 @@ static int convert_node_map_to_list(struct ctdb_context *ctdb,
node->name = talloc_asprintf(node, "%s:%u", node->name = talloc_asprintf(node, "%s:%u",
ctdb_addr_to_str(&node->address), ctdb_addr_to_str(&node->address),
ctdb_addr_to_port(&node->address)); ctdb_addr_to_port(&node->address));
CTDB_NO_MEMORY(ctdb, node->name);
node->flags = node_map->node[i].flags; node->flags = node_map->node[i].flags;
if (!(node->flags & NODE_FLAGS_DELETED)) { if (!(node->flags & NODE_FLAGS_DELETED)) {