From 3e0aae8984ce6aefc8a431271245c33087867463 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Fri, 8 Jan 2016 00:50:45 +0000 Subject: The root of an .EQ tree is always EQN_ROOT, never EQN_LIST, so delete a redundant NULL check that confused Coverity in CID 1257471; issue reported by wiz@, patch differs from what christos@ did in NetBSD. No functional change. --- eqn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eqn.c b/eqn.c index b84ce7e5..2d979dcd 100644 --- a/eqn.c +++ b/eqn.c @@ -987,7 +987,7 @@ this_tok: parent->right = mandoc_strndup(start, sz); } parent = parent->parent; - if (EQN_TOK_BRACE_CLOSE == tok && parent && + if (tok == EQN_TOK_BRACE_CLOSE && (parent->type == EQN_PILE || parent->type == EQN_MATRIX)) parent = parent->parent; -- cgit