From 7e7a53d5ab61be8ef2387c030b18fea209676917 Mon Sep 17 00:00:00 2001 From: David Gibson Date: Tue, 4 Apr 2017 23:46:44 +1000 Subject: [PATCH] agar: Remove unnecessary NULL check At this point the construction of the function above means that nn cannot be NULL. Found by Coverity Scan. Signed-off-by: David Gibson --- ccan/agar/agar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccan/agar/agar.c b/ccan/agar/agar.c index aa462840..0baab325 100644 --- a/ccan/agar/agar.c +++ b/ccan/agar/agar.c @@ -59,7 +59,7 @@ static struct aga_node *nr_to_n(struct agar_state *sr, const void *nr) assert(rc); } - return nn ? &nn->n : NULL; + return &nn->n; } static const void *n_to_nr(struct agar_state *sr, const struct aga_node *n) -- 2.39.5