From: Rafael Zalamena Date: Mon, 3 Jun 2019 14:11:34 +0000 (-0300) Subject: lib: fix northbound static analyzer warning X-Git-Tag: base_7.2~144^2~10 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=020a3906495ee68b8d070efa2f2d79e26363c67e;p=mirror%2Ffrr.git lib: fix northbound static analyzer warning Make the function parameter `const` so the analyzer doesn't suspect we are trying to change its value. Signed-off-by: Rafael Zalamena --- diff --git a/lib/northbound_cli.c b/lib/northbound_cli.c index c96bfbdb91..c691bb27aa 100644 --- a/lib/northbound_cli.c +++ b/lib/northbound_cli.c @@ -440,7 +440,7 @@ static int nb_cli_candidate_load_transaction(struct vty *vty, * This function detects whether next node in the iteration is upwards, * then return the node otherwise return NULL. */ -static struct lyd_node *ly_iter_next_up(struct lyd_node *elem) +static struct lyd_node *ly_iter_next_up(const struct lyd_node *elem) { /* Are we going downwards? Is this still not a leaf? */ if (!(elem->schema->nodetype & (LYS_LEAF | LYS_LEAFLIST | LYS_ANYDATA)))