diff options
author | Kingwel Xie <kingwel.xie@ericsson.com> | 2019-03-11 03:53:48 -0400 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2019-03-26 13:49:31 +0000 |
commit | 7ced7726d73c8588bdee8866e072c40d504db6c5 (patch) | |
tree | bd627177c2bd6b01425c6ee667e741ae9d63160b | |
parent | 32ee2f1dcad744eac03ef367d3c021f65b47faf1 (diff) |
node: vector must be checked with vec_header
see register_node, node-name might be a vector
Change-Id: I883ec51c1fa9aa4da4ba6cba415a39bb6a4331e1
Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
-rw-r--r-- | src/vlib/node.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vlib/node.c b/src/vlib/node.c index af323c4d63c..49c7a40b572 100644 --- a/src/vlib/node.c +++ b/src/vlib/node.c @@ -47,7 +47,7 @@ vlib_get_node_by_name (vlib_main_t * vm, u8 * name) vlib_node_main_t *nm = &vm->node_main; uword *p; u8 *key = name; - if (!clib_mem_is_heap_object (key)) + if (!clib_mem_is_heap_object (vec_header (key, 0))) key = format (0, "%s", key); p = hash_get (nm->node_by_name, key); if (key != name) |