Skip to contentSkip to conversation

tools/xenstored: remove unneeded check in create_node()

PATCH In review Juergen Gross 2 participants 2 messages Apr 21 – Apr 22

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 tools/xenstored: remove unneeded check in create_node()

create_node() is called only for issued xenstore commands. This means that the "conn" parameter is never NULL.

Remove checking whether "conn" is not NULL.

Coverity ID: 1690859

---
V2:
- added Coverity ID (Jan Beulich)

---
 tools/xenstored/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tools/xenstored/core.c +1 -1
index 4786a2a82e..34cb266e8a 100644
@@ -1524,7 +1524,7 @@ static struct node *create_node(struct connection *conn, const void *ctx,
 	if (!node)
 		return NULL;
 
-	if (conn && conn->transaction)
+	if (conn->transaction)
 		ta_node_created(conn->transaction);
 
 	node->data = data;
Signature · 1 line
2.53.0