summaryrefslogtreecommitdiff
path: root/lib/command_match.c
diff options
context:
space:
mode:
authorRenato Westphal <renato@openbsd.org>2018-04-15 19:10:50 -0300
committerGitHub <noreply@github.com>2018-04-15 19:10:50 -0300
commitaecba4e88ae7ca5a14df178cbd1982812c5cd489 (patch)
tree16d7e3c38df7da9c373049a5823b74ad46a6efa5 /lib/command_match.c
parent6b4fdc1cb134ebf0b03df22426aa13c5c51984f8 (diff)
parentbd6b2706b31f49df13927a055e2e824d3357ce6a (diff)
Merge pull request #2054 from qlyoung/sa-fixes
Static analyzer fixes
Diffstat (limited to 'lib/command_match.c')
-rw-r--r--lib/command_match.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/command_match.c b/lib/command_match.c
index f6b07a0b20..99ec03e0c2 100644
--- a/lib/command_match.c
+++ b/lib/command_match.c
@@ -99,6 +99,9 @@ enum matcher_rv command_match(struct graph *cmdgraph, vector vline,
struct listnode *head = listhead(*argv);
struct listnode *tail = listtail(*argv);
+ assert(head);
+ assert(tail);
+
// delete dummy start node
cmd_token_del((struct cmd_token *)head->data);
list_delete_node(*argv, head);